Null pointer safety.

Fixes https://gitlab.com/kicad/code/kicad/issues/6263
This commit is contained in:
Jeff Young 2020-11-03 15:44:52 +00:00
parent 52e9ec5954
commit 2a8ea25209
1 changed files with 1 additions and 1 deletions

View File

@ -370,7 +370,7 @@ void BACK_ANNOTATE::applyChangelist()
const wxString& pinNumber = entry.first;
const wxString& shortNetName = entry.second;
SCH_PIN* pin = comp->GetPin( pinNumber );
SCH_CONNECTION* conn = pin->Connection( &ref.GetSheetPath() );
SCH_CONNECTION* conn = pin ? pin->Connection( &ref.GetSheetPath() ) : nullptr;
wxString key = shortNetName + ref.GetSheetPath().PathAsString();