pcbnew: Fix crash when GAL fallback fails in some cases

This commit is contained in:
Seth Hillbrand 2018-10-09 09:05:14 -07:00
parent 37c2743fec
commit 808a7d9483
1 changed files with 3 additions and 1 deletions

View File

@ -386,7 +386,9 @@ void PCB_DRAW_PANEL_GAL::OnShow()
// Fallback to software renderer
DisplayError( frame, e.what() );
bool use_gal = SwitchBackend( GAL_TYPE_CAIRO );
frame->UseGalCanvas( use_gal );
if( frame )
frame->UseGalCanvas( use_gal );
}
if( frame )