From 65f4743a44a6a4167ce2f71ec911bf6840a20bdb Mon Sep 17 00:00:00 2001 From: Jeff Young Date: Sun, 22 Jul 2018 15:33:20 +0100 Subject: [PATCH] Sort pads by netlist before running single-pad-net tests. Fixes: lp:1782660 * https://bugs.launchpad.net/kicad/+bug/1782660 --- pcbnew/board_netlist_updater.cpp | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/pcbnew/board_netlist_updater.cpp b/pcbnew/board_netlist_updater.cpp index deb6b14ed2..3f9c79ecf1 100644 --- a/pcbnew/board_netlist_updater.cpp +++ b/pcbnew/board_netlist_updater.cpp @@ -571,13 +571,9 @@ bool BOARD_NETLIST_UPDATER::deleteSinglePadNets() std::vector padlist = m_board->GetPads(); - if( m_isDryRun ) - { - // During a dry run changes are only stored in the m_padNets cache, so we must sort - // the list ourselves. - std::sort( padlist.begin(), padlist.end(), - [ this ]( D_PAD* a, D_PAD* b ) -> bool { return getNetname( a ) < getNetname( b ); } ); - } + // Sort pads by netlist name + std::sort( padlist.begin(), padlist.end(), + [ this ]( D_PAD* a, D_PAD* b ) -> bool { return getNetname( a ) < getNetname( b ); } ); for( unsigned kk = 0; kk < padlist.size(); kk++ ) {