don't treat all geometry collections as points/lines when noding

This commit is contained in:
uclaros 2025-02-20 23:20:19 +02:00 committed by Nyall Dawson
parent feb8023300
commit 9fefd746cf

View File

@ -1457,7 +1457,7 @@ geos::unique_ptr QgsGeos::nodeGeometries( const GEOSGeometry *splitLine, const G
geos::unique_ptr geometryBoundary;
GEOSContextHandle_t context = QgsGeosContext::get();
if ( GEOSGeomTypeId_r( context, geom ) == GEOS_POLYGON || GEOSGeomTypeId_r( context, geom ) == GEOS_MULTIPOLYGON )
if ( GEOSGeom_getDimensions_r( context, geom ) == 2 )
geometryBoundary.reset( GEOSBoundary_r( context, geom ) );
else
geometryBoundary.reset( GEOSGeom_clone_r( context, geom ) );