Patch 8.2.4454
Problem:    Resetting cmdwin_type only for one situation.
Solution:   Reset cmdwin_type before closing windows. (closes #9822)
Files:      src/ui.c, src/window.c, src/testdir/test_exit.vim


*** ../vim-8.2.4453/src/ui.c    2022-02-22 12:08:03.985154998 +0000
--- src/ui.c    2022-02-23 12:13:46.830213287 +0000
***************
*** 1065,1073 ****
      if (silent_mode)  // Normal way to exit for "ex -s"
        getout(0);
      STRCPY(IObuff, _("Vim: Error reading input, exiting...\n"));
- #ifdef FEAT_CMDWIN
-     cmdwin_type = 0;
- #endif
      preserve_exit();
  }
  
--- 1065,1070 ----
*** ../vim-8.2.4453/src/window.c        2022-02-21 17:56:29.621257234 +0000
--- src/window.c        2022-02-23 12:15:05.170106681 +0000
***************
*** 2856,2861 ****
--- 2856,2865 ----
  {
      int               dummy;
  
+ #ifdef FEAT_CMDWIN
+     // avoid an error for switching tabpage with the cmdline window open
+     cmdwin_type = 0;
+ #endif
      while (first_tabpage->tp_next != NULL)
        tabpage_close(TRUE);
  
*** ../vim-8.2.4453/src/testdir/test_exit.vim   2022-02-22 18:48:07.489297350 
+0000
--- src/testdir/test_exit.vim   2022-02-23 12:13:46.830213287 +0000
***************
*** 119,124 ****
--- 119,125 ----
    call writefile([":au VimLeave * call writefile(['l = ' .. v:exiting], 
'Xtestout')", ":tabnew", "q:"], 'Xscript', 'b')
  
    if RunVim([], [], '<Xscript')
+     call assert_equal(1, v:shell_error)
      call assert_equal(['l = 1'], readfile('Xtestout'))
    endif
    call delete('Xscript')
*** ../vim-8.2.4453/src/version.c       2022-02-23 12:05:54.486835944 +0000
--- src/version.c       2022-02-23 12:16:27.001961011 +0000
***************
*** 752,753 ****
--- 752,755 ----
  {   /* Add new patch number below this line */
+ /**/
+     4454,
  /**/

-- 
>From "know your smileys":
 @:-()  Elvis Presley

 /// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net   \\\
///                                                                      \\\
\\\        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ ///
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_dev/20220223122421.464ED1C168A%40moolenaar.net.

Raspunde prin e-mail lui