From fd7163b1255526e49a33f6bcb92c0243a5e7cdbd Mon Sep 17 00:00:00 2001 From: Sam Atkins Date: Tue, 14 Dec 2021 16:30:26 +0000 Subject: WindowServer: Stop trying to close windows that are already destroyed --- Userland/Services/WindowServer/Window.cpp | 3 +++ 1 file changed, 3 insertions(+) (limited to 'Userland/Services/WindowServer') diff --git a/Userland/Services/WindowServer/Window.cpp b/Userland/Services/WindowServer/Window.cpp index 722e11495c..d0eaa7a603 100644 --- a/Userland/Services/WindowServer/Window.cpp +++ b/Userland/Services/WindowServer/Window.cpp @@ -898,6 +898,9 @@ void Window::window_menu_activate_default() void Window::request_close() { + if (is_destroyed()) + return; + Event close_request(Event::WindowCloseRequest); event(close_request); } -- cgit v1.2.3