libedit: Prevent segfault when deleting part
emptyScreen() sets the current part to NULL. This gracefully handles the case by allowing a cleared screen when no part is currently selected.
This commit is contained in:
parent
5c8c1cdb8f
commit
4d8534a7a6
|
@ -104,6 +104,9 @@ void SCH_VIEW::DisplayComponent( LIB_PART *aPart )
|
|||
{
|
||||
Clear();
|
||||
|
||||
if( !aPart )
|
||||
return;
|
||||
|
||||
int fgPriority = INT_MAX / 2;
|
||||
int bgPriority = 0;
|
||||
|
||||
|
|
Loading…
Reference in New Issue