[PATCH libXi] Use Data, not Data32 in XIPassiveGrabDevice
Peter Hutterer
peter.hutterer at who-t.net
Wed Jun 1 23:35:12 PDT 2011
Data32 takes and iterates over an array of longs, thus skipping every 4
bytes on LP64. Here we only have arrays of ints, use the normal Data macro
instead.
Signed-off-by: Peter Hutterer <peter.hutterer at who-t.net>
---
tbh, I'm getting mighty confused by the Data/Data32 macros and I'm surprised
this worked before... maybe something else I'm missing here
src/XIPassiveGrab.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/XIPassiveGrab.c b/src/XIPassiveGrab.c
index feef74b..34f1bf3 100644
--- a/src/XIPassiveGrab.c
+++ b/src/XIPassiveGrab.c
@@ -67,9 +67,9 @@ _XIPassiveGrabDevice(Display* dpy, int deviceid, int grabtype, int detail,
buff = calloc(4, req->mask_len);
memcpy(buff, mask->mask, mask->mask_len);
- Data32(dpy, buff, req->mask_len * 4);
+ Data(dpy, buff, req->mask_len * 4);
for (i = 0; i < num_modifiers; i++)
- Data32(dpy, &modifiers_inout[i].modifiers, 4);
+ Data(dpy, (char*)&modifiers_inout[i].modifiers, 4);
free(buff);
--
1.7.5.1
More information about the xorg-devel
mailing list