Verify parent symbol shared pointer is still valid in symbol editor.
This commit is contained in:
parent
b41d446f58
commit
51fd7ca5ed
|
@ -795,7 +795,12 @@ void SYMBOL_EDIT_FRAME::SetCurSymbol( LIB_SYMBOL* aSymbol, bool aUpdateZoom )
|
||||||
}
|
}
|
||||||
else if( IsSymbolAlias() )
|
else if( IsSymbolAlias() )
|
||||||
{
|
{
|
||||||
wxString parentSymbolName = m_symbol->GetParent().lock()->GetName();
|
std::shared_ptr<LIB_SYMBOL> parent = m_symbol->GetParent().lock();
|
||||||
|
|
||||||
|
// Don't assume the parent symbol shared pointer is still valid.
|
||||||
|
wxCHECK( parent, /* void */ );
|
||||||
|
|
||||||
|
wxString parentSymbolName = parent->GetName();
|
||||||
int unit = GetUnit();
|
int unit = GetUnit();
|
||||||
int convert = GetConvert();
|
int convert = GetConvert();
|
||||||
wxString msg;
|
wxString msg;
|
||||||
|
|
Loading…
Reference in New Issue