0
0
mirror of https://github.com/vim/vim.git synced 2025-09-25 03:54:15 -04:00

patch 8.2.2282: length check mismatch with argument of strncmp()

Problem:    Length check mismatch with argument of strncmp(). (Christian
            Brabandt)
Solution:   Adjust length check.
This commit is contained in:
Bram Moolenaar
2021-01-02 20:14:23 +01:00
parent a11919fa44
commit 339c1bdbdf
2 changed files with 6 additions and 6 deletions

View File

@@ -1012,13 +1012,11 @@ fill_input_buf(int exit_on_error UNUSED)
} }
while (len-- > 0) while (len-- > 0)
{ {
/* // If a CTRL-C was typed, remove it from the buffer and set
* If a CTRL-C was typed, remove it from the buffer and set // got_int. Also recognize CTRL-C with modifyOtherKeys set, in two
* got_int. Also recognize CTRL-C with modifyOtherKeys set, in two // forms.
* forms.
*/
if (ctrl_c_interrupts && (inbuf[inbufcount] == 3 if (ctrl_c_interrupts && (inbuf[inbufcount] == 3
|| (len >= 9 && STRNCMP(inbuf + inbufcount, || (len >= 10 && STRNCMP(inbuf + inbufcount,
"\033[27;5;99~", 10) == 0) "\033[27;5;99~", 10) == 0)
|| (len >= 7 && STRNCMP(inbuf + inbufcount, || (len >= 7 && STRNCMP(inbuf + inbufcount,
"\033[99;5u", 7) == 0))) "\033[99;5u", 7) == 0)))

View File

@@ -750,6 +750,8 @@ static char *(features[]) =
static int included_patches[] = static int included_patches[] =
{ /* Add new patch number below this line */ { /* Add new patch number below this line */
/**/
2282,
/**/ /**/
2281, 2281,
/**/ /**/