diff --git a/pcbnew/router/pns_topology.cpp b/pcbnew/router/pns_topology.cpp index c4b7023ef6..c11317f2f3 100644 --- a/pcbnew/router/pns_topology.cpp +++ b/pcbnew/router/pns_topology.cpp @@ -74,11 +74,10 @@ const TOPOLOGY::JOINT_SET TOPOLOGY::ConnectedJoints( JOINT* aStart ) for( ITEM* item : current->LinkList() ) { - if( item->OfKind( ITEM::SEGMENT_T ) ) + if( item->OfKind( ITEM::SEGMENT_T | ITEM::ARC_T ) ) { - SEGMENT* seg = static_cast( item ); - JOINT* a = m_world->FindJoint( seg->Seg().A, seg ); - JOINT* b = m_world->FindJoint( seg->Seg().B, seg ); + JOINT* a = m_world->FindJoint( item->Anchor( 0 ), item );; + JOINT* b = m_world->FindJoint( item->Anchor( 1 ), item );; JOINT* next = ( *a == *current ) ? b : a; if( processed.find( next ) == processed.end() )