diff src/misc2.c @ 20380:79c870b68cf3 v8.2.0745

patch 8.2.0745: crash on exit when not all popups are closed Commit: https://github.com/vim/vim/commit/06f0853cb0b10364b22e5607fdecd35b3936e9ea Author: Bram Moolenaar <Bram@vim.org> Date: Tue May 12 23:45:16 2020 +0200 patch 8.2.0745: crash on exit when not all popups are closed Problem: Crash on exit when not all popups are closed. Solution: Close popups when freeing all memory. Disable checking for popup when editing a file for now.
author Bram Moolenaar <Bram@vim.org>
date Wed, 13 May 2020 00:00:03 +0200
parents 2e5e86ff7596
children 42ab4d40e78f
line wrap: on
line diff
--- a/src/misc2.c
+++ b/src/misc2.c
@@ -1069,6 +1069,14 @@ free_all_mem(void)
 # if defined(FEAT_BEVAL_TERM)
     ui_remove_balloon();
 # endif
+# if defined(FEAT_PROP_POPUP)
+    if (curwin != NULL)
+    {
+	while (popup_is_popup(curwin))
+	    popup_close_with_retval(curwin, 0);
+	close_all_popups();
+    }
+# endif
 
     // Clear user commands (before deleting buffers).
     ex_comclear(NULL);
@@ -3144,8 +3152,7 @@ call_shell(char_u *cmd, int opt)
     if (p_verbose > 3)
     {
 	verbose_enter();
-	smsg(_("Calling shell to execute: \"%s\""),
-						    cmd == NULL ? p_sh : cmd);
+	smsg(_("Calling shell to execute: \"%s\""), cmd == NULL ? p_sh : cmd);
 	out_char('\n');
 	cursor_on();
 	verbose_leave();