From 32626970a0b78ffce6a302d0dd5e1fbe49c66e5c Mon Sep 17 00:00:00 2001 From: Jeff Young Date: Sun, 4 Jun 2023 23:00:44 +0100 Subject: [PATCH] Prevent Sentry KICAD-MM crash. It'd be nicer to know what happens, but we don't have a reproducible case, so this "fix" will at least prevent that particular crash. (cherry picked from commit 0091b9f89720ec52e613a932882d70e75ada2868) --- pcbnew/footprint_edit_frame.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pcbnew/footprint_edit_frame.cpp b/pcbnew/footprint_edit_frame.cpp index 57c2e092d4..1f26bb4c78 100644 --- a/pcbnew/footprint_edit_frame.cpp +++ b/pcbnew/footprint_edit_frame.cpp @@ -811,7 +811,7 @@ void FOOTPRINT_EDIT_FRAME::OnUpdateLoadFootprintFromBoard( wxUpdateUIEvent& aEve { PCB_EDIT_FRAME* frame = (PCB_EDIT_FRAME*) Kiway().Player( FRAME_PCB_EDITOR, false ); - aEvent.Enable( frame && frame->GetBoard()->GetFirstFootprint() != nullptr ); + aEvent.Enable( frame != nullptr ); }