Skip to content

Commit

Permalink
patch 9.0.0801: the modifyOtherKeys flag is set when it should not
Browse files Browse the repository at this point in the history
Problem:    The modifyOtherKeys flag is set when it should not.
Solution:   Do not handle special key codes with a modifer value above 16 as a
            modifyOtherKeys value. (issue #11403)
  • Loading branch information
brammool committed Oct 19, 2022
1 parent d505c82 commit 7609c88
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/term.c
Original file line number Diff line number Diff line change
Expand Up @@ -5045,8 +5045,11 @@ handle_csi(
// Key with modifier:
// {lead}27;{modifier};{key}~
// {lead}{key};{modifier}u
else if ((arg[0] == 27 && argc == 3 && trail == '~')
|| (argc == 2 && trail == 'u'))
// Only handles four modifiers, this won't work if the modifier value is
// more than 16.
else if (((arg[0] == 27 && argc == 3 && trail == '~')
|| (argc == 2 && trail == 'u'))
&& arg[1] <= 16)
{
return len + handle_key_with_modifier(arg, trail,
csi_len, offset, buf, bufsize, buflen);
Expand Down
2 changes: 2 additions & 0 deletions src/version.c
Original file line number Diff line number Diff line change
Expand Up @@ -695,6 +695,8 @@ static char *(features[]) =

static int included_patches[] =
{ /* Add new patch number below this line */
/**/
801,
/**/
800,
/**/
Expand Down

0 comments on commit 7609c88

Please sign in to comment.