summaryrefslogtreecommitdiff
path: root/Xi
diff options
context:
space:
mode:
authorPeter Hutterer <peter.hutterer@who-t.net>2013-10-28 12:10:10 +1000
committerPeter Hutterer <peter.hutterer@who-t.net>2013-10-29 13:40:52 +1000
commit4292a39c8014f9f4920bed3001802e4a3e523c5e (patch)
treece0dab7f5592a927e559027879b9334f8591a89f /Xi
parent83bb366e71ef41165998eed2934208f84714a37e (diff)
Xi: fix logic error when calculating emulated motion events
gcc -Wlogical-op exevents.c: In function 'DeliverEmulatedMotionEvent': exevents.c:1480:13: warning: logical 'or' of collectively exhaustive tests is always true [-Wlogical-op] The relevant snippet of exevents.c: 1479 if (ti->listeners[0].type != LISTENER_POINTER_REGULAR || 1480 ti->listeners[0].type != LISTENER_POINTER_GRAB) 1481 return; This condition was always true, causing dropped motion events. Reported-by: Alan Coopersmith <alan.coopersmith@oracle.com> Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net> Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Diffstat (limited to 'Xi')
-rw-r--r--Xi/exevents.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Xi/exevents.c b/Xi/exevents.c
index fd4b80c48..5dc902054 100644
--- a/Xi/exevents.c
+++ b/Xi/exevents.c
@@ -1476,7 +1476,7 @@ DeliverEmulatedMotionEvent(DeviceIntPtr dev, TouchPointInfoPtr ti,
GrabPtr grab;
XI2Mask *mask;
- if (ti->listeners[0].type != LISTENER_POINTER_REGULAR ||
+ if (ti->listeners[0].type != LISTENER_POINTER_REGULAR &&
ti->listeners[0].type != LISTENER_POINTER_GRAB)
return;