From 037772fe3cc5ce6af562512aedb46ea836cdd679 Mon Sep 17 00:00:00 2001 From: Tomasz Wlostowski Date: Mon, 3 Aug 2015 10:45:30 +0200 Subject: [PATCH] Corrected SHAPE_POLY_SET::pointInPolygon() return value. --- common/geometry/shape_poly_set.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/geometry/shape_poly_set.cpp b/common/geometry/shape_poly_set.cpp index be9ce18c03..92709b6159 100644 --- a/common/geometry/shape_poly_set.cpp +++ b/common/geometry/shape_poly_set.cpp @@ -701,7 +701,7 @@ bool SHAPE_POLY_SET::pointInPolygon( const VECTOR2I& aP, const SHAPE_LINE_CHAIN& (int64_t)( ipNext.x - aP.x ) * (int64_t)( ip.y - aP.y ); if( !d ) - return -1; + return true; if( ( d > 0 ) == ( ipNext.y > ip.y ) ) result = 1 - result;