mirror of
https://gitlab.com/kicad/code/kicad.git
synced 2025-09-14 02:03:12 +02:00
schematic: prevent crash in symbol browser with no grids
This commit is contained in:
parent
92ef03cf15
commit
36ee61dfe4
@ -65,6 +65,11 @@ void COMMON_TOOLS::Reset( RESET_REASON aReason )
|
||||
return;
|
||||
|
||||
GRID_SETTINGS& settings = m_frame->GetWindowSettings( m_toolMgr->GetSettings() )->grid;
|
||||
|
||||
// Protect against misconfigured settings with no grids
|
||||
if( settings.grids.empty() )
|
||||
settings.grids = m_frame->config()->DefaultGridSizeList();
|
||||
|
||||
EDA_IU_SCALE scale = m_frame->GetIuScale();
|
||||
|
||||
for( GRID& gridDef : settings.grids )
|
||||
|
Loading…
x
Reference in New Issue
Block a user