summaryrefslogtreecommitdiff
path: root/Xext/xvmc.c
diff options
context:
space:
mode:
authorPeter Hutterer <peter.hutterer@who-t.net>2009-07-06 12:20:21 +1000
committerPeter Hutterer <peter.hutterer@who-t.net>2009-07-14 10:14:01 +1000
commit7b9e84e320a6f6449fe7bc58a8d6a094ae37b86c (patch)
tree570039663c3361ee3b885ace9d42084d94010fe6 /Xext/xvmc.c
parentaa19d355125a10b1a385c8f134d68e79d3d609c7 (diff)
Xext: switch to byte counting functions
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Diffstat (limited to 'Xext/xvmc.c')
-rw-r--r--Xext/xvmc.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/Xext/xvmc.c b/Xext/xvmc.c
index 879a222bd..b7bb0fc1b 100644
--- a/Xext/xvmc.c
+++ b/Xext/xvmc.c
@@ -153,7 +153,7 @@ ProcXvMCListSurfaceTypes(ClientPtr client)
rep.type = X_Reply;
rep.sequenceNumber = client->sequence;
rep.num = (adaptor) ? adaptor->num_surfaces : 0;
- rep.length = rep.num * sizeof(xvmcSurfaceInfo) >> 2;
+ rep.length = bytes_to_int32(rep.num * sizeof(xvmcSurfaceInfo));
WriteToClient(client, sizeof(xvmcListSurfaceTypesReply), (char*)&rep);
@@ -519,7 +519,7 @@ ProcXvMCListSubpictureTypes(ClientPtr client)
if(surface->compatible_subpictures)
rep.num = surface->compatible_subpictures->num_xvimages;
- rep.length = rep.num * sizeof(xvImageFormatInfo) >> 2;
+ rep.length = bytes_to_int32(rep.num * sizeof(xvImageFormatInfo));
WriteToClient(client, sizeof(xvmcListSubpictureTypesReply), (char*)&rep);
@@ -588,8 +588,8 @@ ProcXvMCGetDRInfo(ClientPtr client)
rep.major = pScreenPriv->major;
rep.minor = pScreenPriv->minor;
rep.patchLevel = pScreenPriv->patchLevel;
- rep.nameLen = (strlen(pScreenPriv->clientDriverName) + 4) >> 2;
- rep.busIDLen = (strlen(pScreenPriv->busID) + 4) >> 2;
+ rep.nameLen = bytes_to_int32(strlen(pScreenPriv->clientDriverName) + 1);
+ rep.busIDLen = bytes_to_int32(strlen(pScreenPriv->busID) + 1);
rep.length = rep.nameLen + rep.busIDLen;
rep.nameLen <<=2;