]> granicus.if.org Git - postgis/commitdiff
Fixed a bug in lwcollection_same
authorSandro Santilli <strk@keybit.net>
Fri, 26 Nov 2004 14:55:05 +0000 (14:55 +0000)
committerSandro Santilli <strk@keybit.net>
Fri, 26 Nov 2004 14:55:05 +0000 (14:55 +0000)
git-svn-id: http://svn.osgeo.org/postgis/trunk@1112 b70326c6-7e19-0410-871a-916f4a2858ee

lwgeom/lwcollection.c

index 95639b6f67c7b25aa2e1cefe22426e56575339a8..dcdef6a07b2d5d1d0f8b294cf03639a48657c869 100644 (file)
@@ -300,9 +300,11 @@ lwcollection_same(const LWCOLLECTION *c1, const LWCOLLECTION *c2)
        if ( TYPE_GETTYPE(c1->type) != TYPE_GETTYPE(c2->type) ) return 0;
        if ( c1->ngeoms != c2->ngeoms ) return 0;
 
+       lwnotice("lwcollection_same called");
+
        for (i=0; i<c1->ngeoms; i++)
        {
-               if ( ! lwgeom_same(c1->geoms[0], c2->geoms[1]) )
+               if ( ! lwgeom_same(c1->geoms[i], c2->geoms[i]) )
                        return 0;
        }
        return 1;