GUACAMOLE-313: Clarify logic testing for Unicode keysyms.

This commit is contained in:
Michael Jumper 2018-01-30 15:26:05 -08:00
parent 5f5b4ea8eb
commit cfd69cd122

View File

@ -222,7 +222,7 @@ static guaclog_keydef* guaclog_get_unicode_key(int keysym) {
int mask, bytes;
/* Translate only if keysym maps to Unicode */
if (keysym < 0x00 || (keysym > 0xFF && (keysym & 0xFFFF0000) != 0x01000000))
if (keysym < 0x00 || (keysym > 0xFF && (keysym | 0xFFFF) != 0x0100FFFF))
return NULL;
int codepoint = keysym & 0xFFFF;