summaryrefslogtreecommitdiff
path: root/Xi/opendev.c
diff options
context:
space:
mode:
authorPeter Hutterer <peter.hutterer@who-t.net>2009-07-03 13:57:14 +1000
committerPeter Hutterer <peter.hutterer@who-t.net>2009-07-14 10:05:53 +1000
commit7dd415aa6a3959f15276741db168ba264948ecfe (patch)
tree84e5b697f073722936dc82f138255f71ef2153d4 /Xi/opendev.c
parent912402fd71144bcee255141efe12a78abad39240 (diff)
Xi: use byte-counting macros instead of manual calculation.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Diffstat (limited to 'Xi/opendev.c')
-rw-r--r--Xi/opendev.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Xi/opendev.c b/Xi/opendev.c
index 46d55a820..3844d25a2 100644
--- a/Xi/opendev.c
+++ b/Xi/opendev.c
@@ -150,7 +150,7 @@ ProcXOpenDevice(ClientPtr client)
}
evbase[j].class = OtherClass;
evbase[j++].event_type_base = event_base[OtherClass];
- rep.length = (j * sizeof(xInputClassInfo) + 3) >> 2;
+ rep.length = bytes_to_int32(j * sizeof(xInputClassInfo));
rep.num_classes = j;
WriteReplyToClient(client, sizeof(xOpenDeviceReply), &rep);
WriteToClient(client, j * sizeof(xInputClassInfo), (char *)evbase);