diff options
author | marha <marha@users.sourceforge.net> | 2012-05-21 09:10:35 +0200 |
---|---|---|
committer | marha <marha@users.sourceforge.net> | 2012-05-21 09:10:35 +0200 |
commit | f543ceaca6820260f15a4eff86938214cf43c7d2 (patch) | |
tree | d66901c0385bd008ba46600be695c500daa78c8f /xorg-server/test/xi2/protocol-xiquerydevice.c | |
parent | 062c45ff0df6a52080dcd74433710d47127cbe29 (diff) | |
download | vcxsrv-f543ceaca6820260f15a4eff86938214cf43c7d2.tar.gz vcxsrv-f543ceaca6820260f15a4eff86938214cf43c7d2.tar.bz2 vcxsrv-f543ceaca6820260f15a4eff86938214cf43c7d2.zip |
fontconfig mesa xkeyboard-config xserver pixman git update 21 Mar 2012
Diffstat (limited to 'xorg-server/test/xi2/protocol-xiquerydevice.c')
-rw-r--r-- | xorg-server/test/xi2/protocol-xiquerydevice.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/xorg-server/test/xi2/protocol-xiquerydevice.c b/xorg-server/test/xi2/protocol-xiquerydevice.c index 5e59e8084..9d13bbb6f 100644 --- a/xorg-server/test/xi2/protocol-xiquerydevice.c +++ b/xorg-server/test/xi2/protocol-xiquerydevice.c @@ -32,6 +32,7 @@ #include <X11/Xatom.h> #include "inputstr.h" #include "extinit.h" +#include "exglobals.h" #include "scrnintstr.h" #include "xkbsrv.h" @@ -54,9 +55,9 @@ struct test_data { }; static void reply_XIQueryDevice_data(ClientPtr client, int len, char *data, - void *userdata); + void *closure); static void reply_XIQueryDevice(ClientPtr client, int len, char *data, - void *userdata); + void *closure); /* reply handling for the first bytes that constitute the reply */ static void @@ -86,10 +87,10 @@ reply_XIQueryDevice(ClientPtr client, int len, char *data, void *userdata) /* reply handling for the trailing bytes that constitute the device info */ static void -reply_XIQueryDevice_data(ClientPtr client, int len, char *data, void *userdata) +reply_XIQueryDevice_data(ClientPtr client, int len, char *data, void *closure) { int i, j; - struct test_data *querydata = (struct test_data *) userdata; + struct test_data *querydata = (struct test_data *) closure; DeviceIntPtr dev; xXIDeviceInfo *info = (xXIDeviceInfo *) data; @@ -222,7 +223,7 @@ reply_XIQueryDevice_data(ClientPtr client, int len, char *data, void *userdata) any->type == XIValuatorClass); if (any->type == XIButtonClass) { - int len; + int l; xXIButtonInfo *bi = (xXIButtonInfo *) any; if (client->swapped) @@ -230,10 +231,9 @@ reply_XIQueryDevice_data(ClientPtr client, int len, char *data, void *userdata) assert(bi->num_buttons == devices.vcp->button->numButtons); - len = - 2 + bi->num_buttons + + l = 2 + bi->num_buttons + bytes_to_int32(bits_to_bytes(bi->num_buttons)); - assert(bi->length == len); + assert(bi->length == l); } else if (any->type == XIValuatorClass) { xXIValuatorInfo *vi = (xXIValuatorInfo *) any; |