]> granicus.if.org Git - postgis/commitdiff
Additional comments regarding use of lwgeom_as_multi() and the
authorBborie Park <bkpark at ucdavis.edu>
Fri, 13 Jul 2012 23:28:44 +0000 (23:28 +0000)
committerBborie Park <bkpark at ucdavis.edu>
Fri, 13 Jul 2012 23:28:44 +0000 (23:28 +0000)
lwgeom_clone_deep()

git-svn-id: http://svn.osgeo.org/postgis/trunk@10056 b70326c6-7e19-0410-871a-916f4a2858ee

raster/rt_core/rt_api.c

index 5fbe39702183b2e26d858446a86bc61b199053e6..9c645605ec2b9afe97a1146879fda2dd061d7589 100644 (file)
@@ -12090,6 +12090,8 @@ LWMPOLY* rt_raster_surface(rt_raster raster, int nband) {
                        /*
                                lwgeom_as_multi() only does a shallow clone internally
                                so input and output geometries may share memory
+                               hence the deep clone of the output geometry for returning
+                               is the only way to guarentee the memory isn't shared
                        */
                        mpoly = lwgeom_as_multi(tmp);
                        tmp2 = lwgeom_clone_deep(mpoly);