Skip to content

Commit

Permalink
Add safety check
Browse files Browse the repository at this point in the history
Refs #44445
  • Loading branch information
nyalldawson committed Aug 2, 2021
1 parent 33dcd13 commit 30f87a7
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/core/pal/pointset.cpp
Expand Up @@ -558,6 +558,8 @@ void PointSet::offsetCurveByDistance( double distance )
try
{
newGeos = GEOSOffsetCurve_r( geosctxt, mGeos, distance, 0, GEOSBUF_JOIN_MITRE, 2 );
if ( !newGeos )
return;

// happens sometime, if the offset curve self-intersects
if ( GEOSGeomTypeId_r( geosctxt, newGeos ) == GEOS_MULTILINESTRING )
Expand Down

0 comments on commit 30f87a7

Please sign in to comment.