>From c544ffbf0ed005729f40d358a39cbf01b3577795 Mon Sep 17 00:00:00 2001 From: Alan Third Date: Sat, 7 Oct 2017 16:00:49 +0100 Subject: [PATCH] Fix crash when closing fullscreen frame on macOS (bug#28661) * src/nsterm.m (EmacsView::windowWillResize): Return new frame size unmodified if the frame isn't live. --- src/nsterm.m | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/nsterm.m b/src/nsterm.m index f0b6a70dae..abfdffc9f5 100644 --- a/src/nsterm.m +++ b/src/nsterm.m @@ -6893,6 +6893,9 @@ - (NSSize)windowWillResize: (NSWindow *)sender toSize: (NSSize)frameSize NSTRACE_RECT ("[sender frame]", [sender frame]); NSTRACE_FSTYPE ("fs_state", fs_state); + if (!FRAME_LIVE_P (emacsframe)) + return frameSize; + if (fs_state == FULLSCREEN_MAXIMIZED && (maximized_width != (int)frameSize.width || maximized_height != (int)frameSize.height)) -- 2.14.1