diff options
author | Sergey Vojtovich <svoj@mariadb.org> | 2015-08-25 11:46:31 +0400 |
---|---|---|
committer | Sergey Vojtovich <svoj@mariadb.org> | 2015-08-25 11:46:31 +0400 |
commit | 27444871a8f30e49fd8f52acdade55e723cacae6 (patch) | |
tree | 6fc17ca0fe04ee905d71cee5105a05c70a5453e4 /sql/item_geofunc.cc | |
parent | c18110bd52770eec7427ca4ef5174118a9db0872 (diff) | |
download | mariadb-git-27444871a8f30e49fd8f52acdade55e723cacae6.tar.gz |
UNINIT_VAR() fixes
Restored self-initialization version of UNINIT_VAR() for all gcc versions.
Fixed UNINIT_VAR() usage: it is supposed to be used along with declaration.
Diffstat (limited to 'sql/item_geofunc.cc')
-rw-r--r-- | sql/item_geofunc.cc | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/sql/item_geofunc.cc b/sql/item_geofunc.cc index 065ba6d30b4..07059fed4be 100644 --- a/sql/item_geofunc.cc +++ b/sql/item_geofunc.cc @@ -1152,11 +1152,9 @@ static int setup_relate_func(Geometry *g1, Geometry *g2, const char *mask) { int do_store_shapes=1; - uint shape_a, shape_b; + uint UNINIT_VAR(shape_a), UNINIT_VAR(shape_b); uint n_operands= 0; int last_shape_pos; - UNINIT_VAR(shape_a); - UNINIT_VAR(shape_b); last_shape_pos= func->get_next_expression_pos(); if (func->reserve_op_buffer(1)) @@ -2396,12 +2394,10 @@ String *Item_func_pointonsurface::val_str(String *str) Geometry *g; MBR mbr; const char *c_end; - double px, py, x0, y0; + double UNINIT_VAR(px), UNINIT_VAR(py), x0, y0; String *result= 0; const Gcalc_scan_iterator::point *pprev= NULL; uint32 srid; - UNINIT_VAR(px); - UNINIT_VAR(py); null_value= 1; if ((args[0]->null_value || |