mirror of
https://github.com/MariaDB/server.git
synced 2025-08-01 03:47:19 +03:00
Merge from 5.0 for 43414
This commit is contained in:
@ -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);
|
||||
|
Reference in New Issue
Block a user