[QGIS Commit] r12386 - trunk/qgis/src/core
svn_qgis at osgeo.org
svn_qgis at osgeo.org
Wed Dec 9 12:17:35 EST 2009
Author: jef
Date: 2009-12-09 12:17:34 -0500 (Wed, 09 Dec 2009)
New Revision: 12386
Modified:
trunk/qgis/src/core/qgsgeometry.cpp
Log:
crash fix for #2224
Modified: trunk/qgis/src/core/qgsgeometry.cpp
===================================================================
--- trunk/qgis/src/core/qgsgeometry.cpp 2009-12-09 16:43:38 UTC (rev 12385)
+++ trunk/qgis/src/core/qgsgeometry.cpp 2009-12-09 17:17:34 UTC (rev 12386)
@@ -5172,7 +5172,7 @@
return 0;
}
- //make sure there are at least two instersction between line and reshape geometry
+ //make sure there are at least two intersection between line and reshape geometry
GEOSGeometry* intersectGeom = GEOSIntersection( line, reshapeLineGeos );
bool atLeastTwoIntersections = ( GEOSGeomTypeId( intersectGeom ) == GEOS_MULTIPOINT && GEOSGetNumGeometries( intersectGeom ) > 1 );
GEOSGeom_destroy( intersectGeom );
@@ -5334,7 +5334,7 @@
}
//add the longest segment from the probable list for rings (only used for polygon rings)
- if ( isRing )
+ if ( isRing && probableParts.size() > 0 )
{
GEOSGeometry* maxGeom = 0; //the longest geometry in the probabla list
GEOSGeometry* currentGeom = 0;
More information about the QGIS-commit
mailing list