aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/getchar.c
diff options
context:
space:
mode:
authorJustin M. Keyes <justinkz@gmail.com>2018-08-06 19:16:42 +0200
committerGitHub <noreply@github.com>2018-08-06 19:16:42 +0200
commit1593ee7cf21f77168531c959fa9e73933b502d2e (patch)
tree2c2991996429def33fc192009cc408f809c6e687 /src/nvim/getchar.c
parent3aca372ac88b4864c2da00780c01f207bdc58435 (diff)
parent41dbb69a85302e9af5c8b76e0d8217ad7d197f8a (diff)
downloadrneovim-1593ee7cf21f77168531c959fa9e73933b502d2e.tar.gz
rneovim-1593ee7cf21f77168531c959fa9e73933b502d2e.tar.bz2
rneovim-1593ee7cf21f77168531c959fa9e73933b502d2e.zip
Merge #8820 from janlazo/vim-8.0.0671
Diffstat (limited to 'src/nvim/getchar.c')
-rw-r--r--src/nvim/getchar.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/nvim/getchar.c b/src/nvim/getchar.c
index 563608dd1d..e20c75cf7b 100644
--- a/src/nvim/getchar.c
+++ b/src/nvim/getchar.c
@@ -439,7 +439,10 @@ void flush_buffers(int flush_typeahead)
;
typebuf.tb_off = MAXMAPLEN;
typebuf.tb_len = 0;
- } else { /* remove mapped characters at the start only */
+ // Reset the flag that text received from a client or from feedkeys()
+ // was inserted in the typeahead buffer.
+ typebuf_was_filled = false;
+ } else { // remove mapped characters at the start only
typebuf.tb_off += typebuf.tb_maplen;
typebuf.tb_len -= typebuf.tb_maplen;
}
@@ -1077,9 +1080,10 @@ void del_typebuf(int len, int offset)
/* Reset the flag that text received from a client or from feedkeys()
* was inserted in the typeahead buffer. */
- typebuf_was_filled = FALSE;
- if (++typebuf.tb_change_cnt == 0)
+ typebuf_was_filled = false;
+ if (++typebuf.tb_change_cnt == 0) {
typebuf.tb_change_cnt = 1;
+ }
}
/*