Check KiFACE return value
Avoid segfault when cancelling initial global library setup
(Cherry-picked from 3c24017aa4
)
This commit is contained in:
parent
8e82fee494
commit
f1f69c607e
|
@ -113,6 +113,8 @@ int COMMON_CONTROL::ShowLibraryTable( const TOOL_EVENT& aEvent )
|
||||||
try // Sch frame was not available, try to start it
|
try // Sch frame was not available, try to start it
|
||||||
{
|
{
|
||||||
KIFACE* kiface = m_frame->Kiway().KiFACE( KIWAY::FACE_SCH );
|
KIFACE* kiface = m_frame->Kiway().KiFACE( KIWAY::FACE_SCH );
|
||||||
|
|
||||||
|
if( kiface )
|
||||||
kiface->CreateKiWindow( m_frame, DIALOG_SCH_LIBRARY_TABLE, &m_frame->Kiway() );
|
kiface->CreateKiWindow( m_frame, DIALOG_SCH_LIBRARY_TABLE, &m_frame->Kiway() );
|
||||||
}
|
}
|
||||||
catch( ... )
|
catch( ... )
|
||||||
|
|
Loading…
Reference in New Issue