Browse Source

Eagle plugin: avoid hanging if an unexpected keyword is found.

Fixes: lp:1701672
https://bugs.launchpad.net/kicad/+bug/1701672
pull/7/merge
jean-pierre charras 8 years ago
parent
commit
1c5ace4b7a
  1. 9
      pcbnew/eagle_plugin.cpp

9
pcbnew/eagle_plugin.cpp

@ -824,7 +824,12 @@ void EAGLE_PLUGIN::loadElements( wxXmlNode* aElements )
while( element )
{
if( element->GetName() != "element" )
{
wxLogMessage( "expected: <element> read <%s>. Skip it", element->GetName() );
// Get next item
element = element->GetNext();
continue;
}
EELEMENT e( element );
@ -909,7 +914,11 @@ void EAGLE_PLUGIN::loadElements( wxXmlNode* aElements )
while( attribute )
{
if( attribute->GetName() != "attribute" )
{
wxLogMessage( "expected: <attribute> read <%s>. Skip it", attribute->GetName() );
attribute = attribute->GetNext();
continue;
}
EATTR a( attribute );

Loading…
Cancel
Save