diff options
author | Josh Rahm <joshuarahm@gmail.com> | 2023-01-31 19:31:36 +0000 |
---|---|---|
committer | Josh Rahm <joshuarahm@gmail.com> | 2023-01-31 19:31:36 +0000 |
commit | 7cb4c990ec1c0384e419b7bfc9f53b81677fd7b7 (patch) | |
tree | b2b399684eabb4ceff9c40882277313f802214b6 | |
parent | 8896b7ea0d98be33d07ae33fbd4bec47c9520f64 (diff) | |
parent | 4cb64e3b084995a0924d521e89c3e341e2200a6a (diff) | |
download | rneovim-7cb4c990ec1c0384e419b7bfc9f53b81677fd7b7.tar.gz rneovim-7cb4c990ec1c0384e419b7bfc9f53b81677fd7b7.tar.bz2 rneovim-7cb4c990ec1c0384e419b7bfc9f53b81677fd7b7.zip |
Merge branch 'fix_20726' into 20230125_mix
-rw-r--r-- | src/nvim/state.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/nvim/state.c b/src/nvim/state.c index 9ba5f81776..a25cb5b76e 100644 --- a/src/nvim/state.c +++ b/src/nvim/state.c @@ -35,6 +35,8 @@ # include "state.c.generated.h" // IWYU pragma: export #endif +size_t hack_keyfix = 0; + void state_enter(VimState *s) { for (;;) { @@ -85,6 +87,18 @@ getkey: } } + // Hacky "fix" for https://github.com/neovim/neovim/issues/20726 + if (key == 3) { + hack_keyfix ++; + if (hack_keyfix == 100) { + got_int = 0; + hack_keyfix = 0; + goto getkey; + } + } else { + hack_keyfix = 0; + } + if (key == K_EVENT) { // An event handler may use the value of reg_executing. // Clear it if it should be cleared when getting the next character. |