Fix length overestimation when first/last line segment enters a pad.

Fixes https://gitlab.com/kicad/code/kicad/issues/13322
This commit is contained in:
Alex 2022-12-30 16:27:59 +05:00
parent 3f34485013
commit 95f5d92fc6
1 changed files with 1 additions and 2 deletions

View File

@ -381,8 +381,7 @@ const ITEM_SET TOPOLOGY::AssembleTuningPath( ITEM* aStart, SOLID** aStartPad, SO
// Whole segment is inside: clip out this segment
clip = vertex;
}
else if( containsB &&
( aForward ? vertex < aLine.PointCount() - 1 : vertex > 0 ) )
else if( containsB )
{
// Only one point inside: Find the intersection
VECTOR2I loc;