[postgis-devel] [PostGIS] #210: segmentation faults in lwgeom_geos.c:pgis_union_geometry_array

PostGIS trac at osgeo.org
Wed Jun 24 10:30:48 PDT 2009


#210: segmentation faults in lwgeom_geos.c:pgis_union_geometry_array
------------------------+---------------------------------------------------
  Reporter:  dfuhriman  |       Owner:  pramsey      
      Type:  defect     |      Status:  new          
  Priority:  medium     |   Milestone:  postgis 1.3.7
 Component:  postgis    |     Version:  trunk        
Resolution:             |    Keywords:               
------------------------+---------------------------------------------------
Comment (by robe):

 Testing this on
 "POSTGIS="1.4.0b1" GEOS="3.1.1-CAPI-1.6.0" PROJ="Rel. 4.6.1, 21 August
 2008" USE_STATS"
 "PostgreSQL 8.3.0, compiled by Visual C++ build 1400"


 I got an error because I don't have that SRID in my table you are using. I
 also got another error that I couldn't replicate something about SRID -1
 (can't used mixed SRIDs), but haven't been able repeat it.

 So I changed your statement to

 {{{

 SELECT T1.gid as taxlot_id,
        coalesce(st_numgeometries(ST_Union(B2.the_geom)),
 st_numgeometries(ST_Union(ST_Intersection(T1.the_geom,B1.the_geom)))
                 ) as roof_area_sqft
   INTO TABLE example2
   FROM test.T1 as T1
       --  JOIN test.B2 as B2 on
 (st_within(B2.the_geom_centroids,T1.the_geom))
       -- JOIN test.B1 as B1 on (st_intersects(T1.the_geom, B1.the_geom))
         LEFT OUTER JOIN test.B2 as B2 on
 (st_within(B2.the_geom_centroids,T1.the_geom))
         LEFT OUTER JOIN test.B1  as B1 on (st_intersects(T1.the_geom,
 B1.the_geom))
         where T1.gid = 1
        GROUP by T1.gid;

 }}}

 Didn't give me an error. Just gives the expected notice
 NOTICE:  LWGEOM_gist_joinsel called with incorrect join type
 NOTICE:  LWGEOM_gist_joinsel called with incorrect join type
 Query returned successfully with no result in 15 ms.

 So like I said I think this is the same issue with ST_MakeLine some
 strange business going on with how we deal with arrays rather than a GEOS
 bug.  It might be the ordering of the union in new geos makes it hit on
 your machine for this and maybe if you tried it again it may actually
 work.

-- 
Ticket URL: <http://trac.osgeo.org/postgis/ticket/210#comment:4>
PostGIS <http://trac.osgeo.org/postgis/>
PostGIS


More information about the postgis-devel mailing list