diff options
Diffstat (limited to 'src/nvim/getchar.c')
-rw-r--r-- | src/nvim/getchar.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/nvim/getchar.c b/src/nvim/getchar.c index b6e235146e..4ea8eb0513 100644 --- a/src/nvim/getchar.c +++ b/src/nvim/getchar.c @@ -2375,7 +2375,7 @@ inchar ( // Get a character from a script file if there is one. // If interrupted: Stop reading script files, close them all. ptrdiff_t read_size = -1; - while (scriptin[curscript] != NULL && read_size < 0 && !ignore_script) { + while (scriptin[curscript] != NULL && read_size <= 0 && !ignore_script) { char script_char; if (got_int || (read_size = file_read(scriptin[curscript], &script_char, 1)) != 1) { @@ -2397,7 +2397,7 @@ inchar ( } } - if (read_size < 0) { // Did not get a character from script. + if (read_size <= 0) { // Did not get a character from script. // If we got an interrupt, skip all previously typed characters and // return TRUE if quit reading script file. // Stop reading typeahead when a single CTRL-C was read, |