summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Martin <consume.noise@gmail.com>2012-11-07 11:31:01 +0100
committerPeter Hutterer <peter.hutterer@who-t.net>2012-11-19 12:12:48 +1000
commitaa9a9ad08b8a6e7e95de7c2bf45d93dd50f9ca87 (patch)
treec569555a5f86c61f81b1c8246b0312f6d9ff0cef
parentaa9da5eae109154edf740a5c1eee4bf98e8fbd4f (diff)
Xi: Fix modifier swapping in XIPassiveGrabDevice
XIPassiveGrabDevice uses a list of uint32_t as modifier sets. The ModifierInfo struct represents the current modifier states and is therefor used in XIQueryPointer and various events. Signed-off-by: Daniel Martin <consume.noise@gmail.com> Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net> Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
-rw-r--r--Xi/xipassivegrab.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/Xi/xipassivegrab.c b/Xi/xipassivegrab.c
index ddab53dec..62a3a469f 100644
--- a/Xi/xipassivegrab.c
+++ b/Xi/xipassivegrab.c
@@ -50,7 +50,7 @@ int
SProcXIPassiveGrabDevice(ClientPtr client)
{
int i;
- xXIModifierInfo *mods;
+ uint32_t *mods;
REQUEST(xXIPassiveGrabDeviceReq);
@@ -63,12 +63,10 @@ SProcXIPassiveGrabDevice(ClientPtr client)
swaps(&stuff->mask_len);
swaps(&stuff->num_modifiers);
- mods = (xXIModifierInfo *) &stuff[1];
+ mods = (uint32_t *) &stuff[1];
for (i = 0; i < stuff->num_modifiers; i++, mods++) {
- swapl(&mods->base_mods);
- swapl(&mods->latched_mods);
- swapl(&mods->locked_mods);
+ swapl(mods);
}
return ProcXIPassiveGrabDevice(client);