Ensure we are checking all ERC errors
Also, handle the possiblity that we return NULL when calling DeserializeFromString in the case where we don't handle all cases or the file is corrupted
This commit is contained in:
parent
e3e63fb1b8
commit
43a622cadf
|
@ -221,6 +221,7 @@ std::vector<std::reference_wrapper<RC_ITEM>> ERC_ITEM::allItemTypes( {
|
|||
ERC_ITEM::busEntryNeeded,
|
||||
ERC_ITEM::endpointOffGrid,
|
||||
ERC_ITEM::fourWayJunction,
|
||||
ERC_ITEM::duplicatePinError,
|
||||
|
||||
ERC_ITEM::heading_conflicts,
|
||||
ERC_ITEM::duplicateReference,
|
||||
|
|
|
@ -316,6 +316,12 @@ std::vector<SCH_MARKER*> SCHEMATIC::ResolveERCExclusions()
|
|||
{
|
||||
SCH_MARKER* testMarker = SCH_MARKER::DeserializeFromString( this, *it );
|
||||
|
||||
if( !testMarker )
|
||||
{
|
||||
it = settings.m_ErcExclusions.erase( it );
|
||||
continue;
|
||||
}
|
||||
|
||||
if( testMarker->IsLegacyMarker() )
|
||||
{
|
||||
const wxString settingsKey = testMarker->GetRCItem()->GetSettingsKey();
|
||||
|
|
Loading…
Reference in New Issue