From: Sandro Santilli Date: Fri, 27 Jun 2014 07:38:02 +0000 (+0000) Subject: Fix undefined behavior in ptarray_calculate_gbox_geodetic (#2774) X-Git-Tag: 2.2.0rc1~1049 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=9ed149511f71e325c6b8ba89ffbb48101a88a9ee;p=postgis Fix undefined behavior in ptarray_calculate_gbox_geodetic (#2774) Patch by Paul Ramsey git-svn-id: http://svn.osgeo.org/postgis/trunk@12676 b70326c6-7e19-0410-871a-916f4a2858ee --- diff --git a/liblwgeom/lwgeodetic.c b/liblwgeom/lwgeodetic.c index 84cc3f4b7..29a235c5a 100644 --- a/liblwgeom/lwgeodetic.c +++ b/liblwgeom/lwgeodetic.c @@ -2484,6 +2484,7 @@ int ptarray_calculate_gbox_geodetic(const POINTARRAY *pa, GBOX *gbox) assert(gbox); assert(pa); + gbox_init(&edge_gbox); edge_gbox.flags = gbox->flags; if ( pa->npoints == 0 ) return LW_FAILURE;