From 5595e3d16cdae57544b91f01ee6cb6458850aa37 Mon Sep 17 00:00:00 2001 From: Ulrich Sibiller Date: Mon, 13 Mar 2017 20:21:57 +0100 Subject: Keystroke.c: Fix modifier handling Code could not distinguish between ctrl-alt-shift and ctrl-alt. Fixes ArcticaProject/nx-libs#395 --- nx-X11/programs/Xserver/hw/nxagent/Keystroke.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'nx-X11') diff --git a/nx-X11/programs/Xserver/hw/nxagent/Keystroke.c b/nx-X11/programs/Xserver/hw/nxagent/Keystroke.c index 12a5cd49b..6e8c9c2a8 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Keystroke.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Keystroke.c @@ -155,10 +155,11 @@ static Bool modifier_matches(unsigned int mask, int compare_alt_meta, unsigned i } mask &= ~nxagentAltMetaMask; + state &= ~nxagentAltMetaMask; } /* all modifiers except meta/alt have to match exactly, extra bits are evil */ - if ((mask & state) != mask) { + if (mask != state) { ret = False; } -- cgit v1.2.3