summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthieu Herrb <matthieu.herrb@laas.fr>2011-04-01 22:54:54 +0200
committerPeter Hutterer <peter.hutterer@who-t.net>2011-04-07 08:36:59 +1000
commit2f12adb2c914732ae3a328b759d272d8bbbb55a6 (patch)
tree64ef6ad127f9e5ed58e179bd119fa54c36ed1301
parente08a7df54da8aeb343412ed9dda250207dc749f4 (diff)
Xext: fix test on extension number for the swapped case.
Signed-off-by: Matthieu Herrb <matthieu.herrb@laas.fr> Reviewed-by: Julien Cristau <jcristau@debian.org> (cherry picked from commit 552c78592c5e5f52fe16e2429f77c63adf398247)
-rw-r--r--Xext/geext.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Xext/geext.c b/Xext/geext.c
index b37c1a0bd..a6fbb0947 100644
--- a/Xext/geext.c
+++ b/Xext/geext.c
@@ -185,7 +185,7 @@ SGEGenericEvent(xEvent* from, xEvent* to)
xGenericEvent* gefrom = (xGenericEvent*)from;
xGenericEvent* geto = (xGenericEvent*)to;
- if (gefrom->extension > MAXEXTENSIONS)
+ if ((gefrom->extension & 0x7f) > MAXEXTENSIONS)
{
ErrorF("GE: Invalid extension offset for event.\n");
return;