From a572244e62060b69d17f0b424b3fa97184fb9a6e Mon Sep 17 00:00:00 2001 From: ddmoney420 <130018552+ddmoney420@users.noreply.github.com> Date: Mon, 2 Feb 2026 03:10:36 -0700 Subject: [PATCH] fix(v3): add nil check to Focus() to prevent SIGSEGV after Hide (#4922) * fix(v3): add nil check to Focus() to prevent SIGSEGV after Hide The Focus() method was missing a nil/destroyed check on w.impl, causing a SIGSEGV when Focus() is called on a window that has been hidden and potentially destroyed (e.g., when clicking the dock icon after hiding the window on macOS). This aligns Focus() with Show() and Hide() which already have proper guards against nil/destroyed window implementations. Fixes #4890 Co-Authored-By: Claude Opus 4.5 * docs: add changelog entry for Focus() nil check fix Co-Authored-By: Claude Opus 4.5 --------- Co-authored-by: ddmoney420 Co-authored-by: Claude Opus 4.5 Co-authored-by: Lea Anthony --- v3/UNRELEASED_CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/v3/UNRELEASED_CHANGELOG.md b/v3/UNRELEASED_CHANGELOG.md index e5997d5d3..719b9cfe7 100644 --- a/v3/UNRELEASED_CHANGELOG.md +++ b/v3/UNRELEASED_CHANGELOG.md @@ -25,11 +25,11 @@ After processing, the content will be moved to the main changelog and this file ## Fixed +- Fix SIGSEGV crash when calling `Focus()` on a hidden or destroyed window (#4890) by @ddmoney420 - Fix potential panic when setting empty icon or bitmap on Linux (#4923) by @ddmoney420 - Fix ErrorDialog crash when called from service binding on macOS (#3631) by @leaanthony - Make menus to be displayed on Windows OS in `v3\examples\dialogs` by @ndianabasi - Fix race condition causing TypeError during page reload (#4872) by @ddmoney420 - - Fix incorrect output from binding generator tests by removing global state in the `Collector.IsVoidAlias()` method (#4941) by @fbbdev ## Deprecated