Skip to content
Permalink
Browse files

Fix invalid return from QgsCircularString::pointN with negative indices

  • Loading branch information
nyalldawson committed Sep 19, 2017
1 parent e5b1c67 commit 6205ca5ef7ccc03fa27ed33df5fef0f330baa5e5
Showing with 1 addition and 1 deletion.
  1. +1 −1 src/core/geometry/qgscircularstring.cpp
@@ -755,7 +755,7 @@ double QgsCircularString::closestSegment( const QgsPoint &pt, QgsPoint &segmentP

bool QgsCircularString::pointAt( int node, QgsPoint &point, QgsVertexId::VertexType &type ) const
{
if ( node >= numPoints() )
if ( node < 0 || node >= numPoints() )
{
return false;
}

0 comments on commit 6205ca5

Please sign in to comment.
You can’t perform that action at this time.