summaryrefslogtreecommitdiffstats
path: root/src/autocmd.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2020-10-01 20:03:04 +0200
committerBram Moolenaar <Bram@vim.org>2020-10-01 20:03:04 +0200
commit4537bcc88956f86267c25edf8008e0dbde598652 (patch)
tree94d5ab3b790b0aeca8985d8ba2848aecb8d563cc /src/autocmd.c
parent668008be66326ed9e5b1122abede34ed3d2de2d8 (diff)
patch 8.2.1781: writing to prompt buffer interferes with insert modev8.2.1781
Problem: Writing to prompt buffer interferes with insert mode. Solution: Use win_enter() instead of just setting "curwin". (Ben Jackson, closes #7035)
Diffstat (limited to 'src/autocmd.c')
-rw-r--r--src/autocmd.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/autocmd.c b/src/autocmd.c
index d5c61ca6ac..4c2b705963 100644
--- a/src/autocmd.c
+++ b/src/autocmd.c
@@ -1533,7 +1533,7 @@ win_found:
unblock_autocmds();
if (win_valid(aco->save_curwin))
- curwin = aco->save_curwin;
+ win_enter(aco->save_curwin, TRUE);
else
// Hmm, original window disappeared. Just use the first one.
curwin = firstwin;