[QGIS-trac] [Quantum GIS] #1248: QgsGeometry.Union causes Segfault when unioning multi-polyon features

Quantum GIS qgis at qgis.org
Tue Aug 26 09:58:05 EDT 2008


#1248: QgsGeometry.Union causes Segfault when unioning multi-polyon features
---------------------------------------------------------+------------------
   Reporter:  cfarmer                                    |              Owner:  jef          
       Type:  bug                                        |             Status:  new          
   Priority:  critical: causes crash or data corruption  |          Milestone:  Version 1.0.0
  Component:  Vectors                                    |            Version:  HEAD         
   Keywords:                                             |   Platform_version:               
   Platform:  Linux                                      |           Must_fix:  Yes          
Status_info:  0                                          |  
---------------------------------------------------------+------------------
 When unioning two features using QgsGeometry.Union, if one of the features
 is a multi-polygon, QGIS crashes without warning.

 Example (should combine all geometries of a single layer together through
 unioning):

 geom = QgsGeometry()
 geom2 = QgsGeometry()
 provider.getNextFeature(feat)
 geom = feat.geometry()
 while provider.getNextFeature(feat):
     geom2 = feat.geometry()
     geom = geom.Union(geom2)

-- 
Ticket URL: <https://trac.osgeo.org/qgis/ticket/1248>
Quantum GIS <http://qgis.org>
Quantum GIS is an Open Source GIS viewer/editor supporting OGR, PostGIS, and GRASS formats


More information about the QGIS-trac mailing list