patch 8.2.4700: buffer remains active if WinClosed event throws an exception
Problem: Buffer remains active if a WinClosed event throws an exception.
Solution: Ignore aborting() when closing the buffer. (closes #10097)
diff --git a/src/window.c b/src/window.c
index 30fa802..8ec4823 100644
--- a/src/window.c
+++ b/src/window.c
@@ -2493,7 +2493,7 @@
set_bufref(&bufref, curbuf);
win->w_closing = TRUE;
- close_buffer(win, win->w_buffer, action, abort_if_last, FALSE);
+ close_buffer(win, win->w_buffer, action, abort_if_last, TRUE);
if (win_valid_any_tab(win))
win->w_closing = FALSE;
// Make sure curbuf is valid. It can become invalid if 'bufhidden' is