From 57afdf153d2b746867028e9f17f71fbe27bf84c1 Mon Sep 17 00:00:00 2001 From: Seth Hillbrand Date: Tue, 18 Jan 2022 15:58:20 -0800 Subject: [PATCH] Remove unneeded distance calc (cherry picked from commit 857683d372ef55e320e1f147691a694cd621efce) --- libs/kimath/src/geometry/shape_line_chain.cpp | 2 -- 1 file changed, 2 deletions(-) diff --git a/libs/kimath/src/geometry/shape_line_chain.cpp b/libs/kimath/src/geometry/shape_line_chain.cpp index 9f1488f7a6..9cb6b56017 100644 --- a/libs/kimath/src/geometry/shape_line_chain.cpp +++ b/libs/kimath/src/geometry/shape_line_chain.cpp @@ -1503,8 +1503,6 @@ int SHAPE_LINE_CHAIN::PathLength( const VECTOR2I& aP, int aIndex ) const for( int i = 0; i < SegmentCount(); i++ ) { const SEG seg = CSegment( i ); - int d = seg.Distance( aP ); - bool indexMatch = true; if( aIndex >= 0 )