aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/input.c
diff options
context:
space:
mode:
authordundargoc <33953936+dundargoc@users.noreply.github.com>2022-09-28 10:53:44 +0200
committerGitHub <noreply@github.com>2022-09-28 10:53:44 +0200
commitd7358118aa57ec636ef6f84c6ac96f26d8bed32c (patch)
tree22c160c38d884ce267fb9c06550dbc0d8eb9e0b5 /src/nvim/input.c
parente6c214033a4fadf60faf99e95f8e9787e3c5e630 (diff)
downloadrneovim-d7358118aa57ec636ef6f84c6ac96f26d8bed32c.tar.gz
rneovim-d7358118aa57ec636ef6f84c6ac96f26d8bed32c.tar.bz2
rneovim-d7358118aa57ec636ef6f84c6ac96f26d8bed32c.zip
fix: compiler warnings from clang 15 (#20321)
Add -Wno-strict-prototypes flag to external dependencies to suppress cjson warnings. These needs to be fixed upstream first.
Diffstat (limited to 'src/nvim/input.c')
-rw-r--r--src/nvim/input.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/src/nvim/input.c b/src/nvim/input.c
index 0aa9feaca3..681d9d5f9c 100644
--- a/src/nvim/input.c
+++ b/src/nvim/input.c
@@ -83,7 +83,6 @@ int get_keystroke(MultiQueue *events)
int len = 0;
int n;
int save_mapped_ctrl_c = mapped_ctrl_c;
- int waited = 0;
mapped_ctrl_c = 0; // mappings are not used here
for (;;) {
@@ -110,10 +109,8 @@ int get_keystroke(MultiQueue *events)
// Replace zero and K_SPECIAL by a special key code.
n = fix_input_buffer(buf + len, n);
len += n;
- waited = 0;
- } else if (len > 0) {
- waited++; // keep track of the waiting time
}
+
if (n > 0) { // found a termcode: adjust length
len = n;
}