closestDist_sq should be ECOORD_MAX initially.

This commit is contained in:
Alex Shvartzkop 2023-10-23 22:18:45 +03:00
parent 4ffa013467
commit c8b2e2aa07
1 changed files with 1 additions and 1 deletions

View File

@ -1441,7 +1441,7 @@ int PCB_CONTROL::UpdateMessagePanel( const TOOL_EVENT& aEvent )
{
SEG trackSeg( track->GetStart(), track->GetEnd() );
PCB_TRACK* coupledItem = nullptr;
SEG::ecoord closestDist_sq = 0;
SEG::ecoord closestDist_sq = VECTOR2I::ECOORD_MAX;
for( PCB_TRACK* candidate : m_frame->GetBoard()->Tracks() )
{