aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorzeertzjq <zeertzjq@outlook.com>2024-01-16 10:42:09 +0800
committerGitHub <noreply@github.com>2024-01-16 10:42:09 +0800
commit267e90f31d186cc06202f308e1a63fbcc6bbed2c (patch)
treebde7fcc1308098004691309ff4042f0330dbb7fc /src
parenta34451982fe661fcfb6082607a8cf4c22ff51577 (diff)
downloadrneovim-267e90f31d186cc06202f308e1a63fbcc6bbed2c.tar.gz
rneovim-267e90f31d186cc06202f308e1a63fbcc6bbed2c.tar.bz2
rneovim-267e90f31d186cc06202f308e1a63fbcc6bbed2c.zip
fix(edit): don't go to Terminal mode when stopping Insert mode (#27033)
Diffstat (limited to 'src')
-rw-r--r--src/nvim/edit.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/nvim/edit.c b/src/nvim/edit.c
index 3006f423dc..470d57890a 100644
--- a/src/nvim/edit.c
+++ b/src/nvim/edit.c
@@ -402,7 +402,7 @@ static int insert_check(VimState *state)
Insstart_orig = Insstart;
}
- if (curbuf->terminal) {
+ if (curbuf->terminal && !stop_insert_mode) {
// Exit Insert mode and go to Terminal mode.
stop_insert_mode = true;
restart_edit = 'I';