]> granicus.if.org Git - postgis/commitdiff
Do not continue execution of ptarray_to_GEOSCoordSeq on error
authorSandro Santilli <strk@kbt.io>
Mon, 21 Nov 2016 15:27:12 +0000 (15:27 +0000)
committerSandro Santilli <strk@kbt.io>
Mon, 21 Nov 2016 15:27:12 +0000 (15:27 +0000)
git-svn-id: http://svn.osgeo.org/postgis/trunk@15241 b70326c6-7e19-0410-871a-916f4a2858ee

liblwgeom/lwgeom_geos.c

index c635ee70c57296d61529497baefb0596141f8a0d..c9a7dcd20a71c36d4c8f3630ef98832e8092f281 100644 (file)
@@ -225,7 +225,10 @@ ptarray_to_GEOSCoordSeq(const POINTARRAY *pa)
                dims = 3;
 
        if ( ! (sq = GEOSCoordSeq_create(pa->npoints, dims)) )
+       {
                lwerror("Error creating GEOS Coordinate Sequence");
+               return NULL;
+       }
 
        for ( i=0; i < pa->npoints; i++ )
        {