summaryrefslogtreecommitdiff
path: root/sql/spatial.cc
diff options
context:
space:
mode:
authorStaale Smedseng <staale.smedseng@sun.com>2009-08-28 18:21:54 +0200
committerStaale Smedseng <staale.smedseng@sun.com>2009-08-28 18:21:54 +0200
commit5be4c3822691f8bca4c8444ccc77b4b01bc996c1 (patch)
treea1ec5dfbd668a88bc0b6c98db397a421d2b37f21 /sql/spatial.cc
parent169f7da04c4ffc43355d5a632a8013bc4caea39b (diff)
parent1ba25ae47caace207cda0be2b7994a1a845e6cce (diff)
downloadmariadb-git-5be4c3822691f8bca4c8444ccc77b4b01bc996c1.tar.gz
Merge from 5.0 for 43414
Diffstat (limited to 'sql/spatial.cc')
-rw-r--r--sql/spatial.cc13
1 files changed, 3 insertions, 10 deletions
diff --git a/sql/spatial.cc b/sql/spatial.cc
index 97e5fcfa27a..9114c81514d 100644
--- a/sql/spatial.cc
+++ b/sql/spatial.cc
@@ -937,13 +937,10 @@ int Gis_polygon::interior_ring_n(uint32 num, String *result) const
int Gis_polygon::centroid_xy(double *x, double *y) const
{
uint32 n_linear_rings;
- double res_area;
- double res_cx, res_cy;
+ double UNINIT_VAR(res_area);
+ double UNINIT_VAR(res_cx), UNINIT_VAR(res_cy);
const char *data= m_data;
bool first_loop= 1;
- LINT_INIT(res_area);
- LINT_INIT(res_cx);
- LINT_INIT(res_cy);
if (no_data(data, 4))
return 1;
@@ -1638,14 +1635,10 @@ int Gis_multi_polygon::centroid(String *result) const
uint32 n_polygons;
bool first_loop= 1;
Gis_polygon p;
- double res_area, res_cx, res_cy;
+ double UNINIT_VAR(res_area), UNINIT_VAR(res_cx), UNINIT_VAR(res_cy);
double cur_area, cur_cx, cur_cy;
const char *data= m_data;
- LINT_INIT(res_area);
- LINT_INIT(res_cx);
- LINT_INIT(res_cy);
-
if (no_data(data, 4))
return 1;
n_polygons= uint4korr(data);