[PATCH 4/6] dix: GetProximityEvents needs to check up to the last valuator

Peter Hutterer peter.hutterer at who-t.net
Mon Nov 22 19:35:43 PST 2010


valuator_mask_size() returns the highest valuator set as opposed to the
number of set bits (which obviously changes as we unset valuators).

Signed-off-by: Peter Hutterer <peter.hutterer at who-t.net>
---
 dix/getevents.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/dix/getevents.c b/dix/getevents.c
index 5f4fb66..f80e87c 100644
--- a/dix/getevents.c
+++ b/dix/getevents.c
@@ -1248,7 +1248,7 @@ GetProximityEvents(EventList *events, DeviceIntPtr pDev, int type, const Valuato
     valuator_mask_copy(&mask, mask_in);
 
     /* ignore relative axes for proximity. */
-    for (i = 0; i < valuator_mask_num_valuators(&mask); i++)
+    for (i = 0; i < valuator_mask_size(&mask); i++)
     {
         if (valuator_mask_isset(&mask, i) &&
             valuator_get_mode(pDev, i) == Relative)
-- 
1.7.3.2



More information about the xorg-devel mailing list