[postgis-devel] [PostGIS] #1385: ST_Extent() segfaults on null geometries

PostGIS trac at osgeo.org
Sun Dec 18 04:06:47 PST 2011


#1385: ST_Extent() segfaults on null geometries
----------------------+-----------------------------------------------------
 Reporter:  rouault   |       Owner:  pramsey      
     Type:  defect    |      Status:  new          
 Priority:  critical  |   Milestone:  PostGIS 2.0.0
Component:  postgis   |     Version:  trunk        
 Keywords:            |  
----------------------+-----------------------------------------------------
 The following sequence causes a crash in BOX3D_combine(), line 348, on
 "GSERIALIZED *geom = (GSERIALIZED*)PG_DETOAST_DATUM(PG_GETARG_POINTER(1))"

 {{{
 CREATE TABLE test_crash_st_extent ( foo VARCHAR )
 SELECT
 AddGeometryColumn('public','test_crash_st_extent','wkb_geometry',0,'GEOMETRY',2)
 INSERT INTO test_crash_st_extent (foo) VALUES ('bar')
 SELECT ST_Extent(\"wkb_geometry\") FROM test_crash_st_extent
 }}}

 Attached patch fixes the segfault

-- 
Ticket URL: <http://trac.osgeo.org/postgis/ticket/1385>
PostGIS <http://trac.osgeo.org/postgis/>
The PostGIS Trac is used for bug, enhancement & task tracking, a user and developer wiki, and a view into the subversion code repository of PostGIS project.


More information about the postgis-devel mailing list