From 49f3aaf4a111fdab9df4ddc7591e9f48e6290164 Mon Sep 17 00:00:00 2001 From: BlueCannonBall Date: Sun, 5 Apr 2026 16:38:07 -0400 Subject: [PATCH] Add null check for child window in callback Fixes issue #1401 --- src/Fl_win32.cxx | 1 + 1 file changed, 1 insertion(+) diff --git a/src/Fl_win32.cxx b/src/Fl_win32.cxx index 0b2ce2a59..a97d3133d 100644 --- a/src/Fl_win32.cxx +++ b/src/Fl_win32.cxx @@ -1227,6 +1227,7 @@ static void invalidate_gl_win(Fl_Window *glwin) { static BOOL CALLBACK child_window_cb(HWND child_xid, LPARAM data) { Fl_Window *child = fl_find(child_xid); + if (!child) return TRUE; if (data) { float s = *(float*)data; SetWindowPos(child_xid, 0, int(round(child->x() * s)), int(round(child->y() * s)),