Pcbnew: Fix crash when importing a netlist created by a 5.1 Eeschema version.
Fixes #8293 https://gitlab.com/kicad/code/kicad/issues/8293
This commit is contained in:
parent
eb85836234
commit
93d42e9902
|
@ -305,7 +305,9 @@ bool BOARD_NETLIST_UPDATER::updateFootprintParameters( FOOTPRINT* aPcbFootprint,
|
|||
|
||||
// Test for time stamp change.
|
||||
KIID_PATH new_path = aNetlistComponent->GetPath();
|
||||
new_path.push_back( aNetlistComponent->GetKIIDs().front() );
|
||||
|
||||
if( !aNetlistComponent->GetKIIDs().empty() )
|
||||
new_path.push_back( aNetlistComponent->GetKIIDs().front() );
|
||||
|
||||
if( aPcbFootprint->GetPath() != new_path )
|
||||
{
|
||||
|
|
|
@ -42,7 +42,8 @@ void COMPONENT::SetFootprint( FOOTPRINT* aFootprint )
|
|||
m_footprint.reset( aFootprint );
|
||||
KIID_PATH path = m_path;
|
||||
|
||||
path.push_back( m_kiids.front() );
|
||||
if( !m_kiids.empty() )
|
||||
path.push_back( m_kiids.front() );
|
||||
|
||||
if( aFootprint == NULL )
|
||||
return;
|
||||
|
|
Loading…
Reference in New Issue