[postgis-devel] [PostGIS] #681: ST_AsGML and ST_AsKML crashes on POLYGON EMPTY or acts really bizarre

PostGIS trac at osgeo.org
Wed Dec 15 09:48:15 PST 2010


#681: ST_AsGML and ST_AsKML crashes on POLYGON EMPTY or acts really bizarre
----------------------+-----------------------------------------------------
  Reporter:  robe     |       Owner:  colivier     
      Type:  defect   |      Status:  reopened     
  Priority:  medium   |   Milestone:  PostGIS 2.0.0
 Component:  postgis  |     Version:  trunk        
Resolution:           |    Keywords:               
----------------------+-----------------------------------------------------

Comment(by pramsey):

 I have made no fixes to AsGML, I fully expect it to do all kinds of nasty
 things when fed EMPTY.

 For AsKML, I have checked in a fix to the crashing at r6402. Right now I
 return NULL on empty. The 1.5 behavior was that the empty got coerced to
 geometrycollection empty, which then failed the "no geometry collections
 allowed" test and failed with an error. I can change to error out on empty
 if that is preferred. There seems to be no representation for empty in
 KML, although we could invent one (<polygon></polygon>) I'm not sure what
 Google Earth would do with it. Research project?

-- 
Ticket URL: <http://trac.osgeo.org/postgis/ticket/681#comment:11>
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