Commit da51dbe1 authored by jean-pierre charras's avatar jean-pierre charras

Cvpcb fix bug #1183796 and fix bug when a fp lib is not found : the name of...

Cvpcb fix bug  #1183796 and fix bug when a fp lib is not found : the name of the missing file was not displayed in message window.
parent 29613e29
...@@ -77,7 +77,7 @@ bool FOOTPRINT_LIST::ReadFootprintFiles( wxArrayString& aFootprintsLibNames ) ...@@ -77,7 +77,7 @@ bool FOOTPRINT_LIST::ReadFootprintFiles( wxArrayString& aFootprintsLibNames )
if( !filename.FileExists() ) if( !filename.FileExists() )
{ {
m_filesNotFound << filename.GetFullName() << wxT( "\n" ); m_filesNotFound << aFootprintsLibNames[ii] << wxT( "\n" );
continue; continue;
} }
......
...@@ -428,16 +428,11 @@ void CMP_READER::Load( NETLIST* aNetlist ) throw( IO_ERROR, PARSE_ERROR ) ...@@ -428,16 +428,11 @@ void CMP_READER::Load( NETLIST* aNetlist ) throw( IO_ERROR, PARSE_ERROR )
// Find the corresponding item in component list: // Find the corresponding item in component list:
COMPONENT* component = aNetlist->GetComponentByReference( reference ); COMPONENT* component = aNetlist->GetComponentByReference( reference );
// This cannot happen with a valid file. // the corresponding component could be no more existing in netlist:
if( component == NULL ) // this is the case when it is just removed from schematic,
{ // and still exists in footprint assignment list, before this list is updated
wxString msg; // This is an usual case during the life of a design
msg.Printf( _( "Cannot find component \'%s\' in footprint assignment file." ), if( component )
GetChars( reference ) ); component->SetFootprintName( footprint );
THROW_PARSE_ERROR( msg, m_lineReader->GetSource(), m_lineReader->Line(),
m_lineReader->LineNumber(), m_lineReader->Length() );
}
component->SetFootprintName( footprint );
} }
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment