From 36ee61dfe4e8d62c1f5c1f73dc3a596d8ca4f347 Mon Sep 17 00:00:00 2001 From: Mike Williams Date: Tue, 19 Aug 2025 13:57:08 -0400 Subject: [PATCH] schematic: prevent crash in symbol browser with no grids --- common/tool/common_tools.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/common/tool/common_tools.cpp b/common/tool/common_tools.cpp index a6531a72c8..785df235b3 100644 --- a/common/tool/common_tools.cpp +++ b/common/tool/common_tools.cpp @@ -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 )