summaryrefslogtreecommitdiff
path: root/hw
diff options
context:
space:
mode:
Diffstat (limited to 'hw')
-rw-r--r--hw/dmx/dmx.c44
-rw-r--r--hw/dmx/glxProxy/glxcmds.c39
-rw-r--r--hw/dmx/glxProxy/glxcmdsswap.c29
-rw-r--r--hw/dmx/glxProxy/glxsingle.c16
-rw-r--r--hw/dmx/glxProxy/glxvendor.c12
-rw-r--r--hw/dmx/glxProxy/unpack.h12
-rw-r--r--hw/kdrive/ephyr/ephyrdriext.c25
-rw-r--r--hw/kdrive/ephyr/ephyrglxext.c14
-rw-r--r--hw/kdrive/ephyr/ephyrproxyext.c2
-rw-r--r--hw/xfree86/dixmods/extmod/xf86dga2.c34
-rw-r--r--hw/xfree86/dixmods/extmod/xf86vmode.c48
-rw-r--r--hw/xfree86/dri/xf86dri.c25
-rw-r--r--hw/xquartz/applewm.c6
-rw-r--r--hw/xquartz/pseudoramiX.c12
-rw-r--r--hw/xquartz/xpr/appledri.c8
-rw-r--r--hw/xwin/winwindowswm.c4
16 files changed, 154 insertions, 176 deletions
diff --git a/hw/dmx/dmx.c b/hw/dmx/dmx.c
index a226c5db1..5ea133e6b 100644
--- a/hw/dmx/dmx.c
+++ b/hw/dmx/dmx.c
@@ -225,7 +225,7 @@ ProcDMXQueryVersion(ClientPtr client)
swapl(&rep.minorVersion);
swapl(&rep.patchVersion);
}
- WriteToClient(client, sizeof(xDMXQueryVersionReply), (char *) &rep);
+ WriteToClient(client, sizeof(xDMXQueryVersionReply), &rep);
return Success;
}
@@ -247,7 +247,7 @@ ProcDMXSync(ClientPtr client)
swapl(&rep.length);
swapl(&rep.status);
}
- WriteToClient(client, sizeof(xDMXSyncReply), (char *) &rep);
+ WriteToClient(client, sizeof(xDMXSyncReply), &rep);
return Success;
}
@@ -297,7 +297,7 @@ ProcDMXForceWindowCreation(ClientPtr client)
swapl(&rep.length);
swapl(&rep.status);
}
- WriteToClient(client, sizeof(xDMXForceWindowCreationReply), (char *) &rep);
+ WriteToClient(client, sizeof(xDMXForceWindowCreationReply), &rep);
return Success;
}
@@ -317,7 +317,7 @@ ProcDMXGetScreenCount(ClientPtr client)
swapl(&rep.length);
swapl(&rep.screenCount);
}
- WriteToClient(client, sizeof(xDMXGetScreenCountReply), (char *) &rep);
+ WriteToClient(client, sizeof(xDMXGetScreenCountReply), &rep);
return Success;
}
@@ -377,9 +377,9 @@ ProcDMXGetScreenAttributes(ClientPtr client)
swaps(&rep.rootWindowXorigin);
swaps(&rep.rootWindowYorigin);
}
- WriteToClient(client, sizeof(xDMXGetScreenAttributesReply), (char *) &rep);
+ WriteToClient(client, sizeof(xDMXGetScreenAttributesReply), &rep);
if (length)
- WriteToClient(client, length, (char *) attr.displayName);
+ WriteToClient(client, length, attr.displayName);
return Success;
}
@@ -453,8 +453,7 @@ ProcDMXChangeScreensAttributes(ClientPtr client)
swapl(&rep.status);
swapl(&rep.errorScreen);
}
- WriteToClient(client,
- sizeof(xDMXChangeScreensAttributesReply), (char *) &rep);
+ WriteToClient(client, sizeof(xDMXChangeScreensAttributesReply), &rep);
return Success;
}
@@ -503,7 +502,7 @@ ProcDMXAddScreen(ClientPtr client)
swapl(&rep.status);
swapl(&rep.physicalScreen);
}
- WriteToClient(client, sizeof(xDMXAddScreenReply), (char *) &rep);
+ WriteToClient(client, sizeof(xDMXAddScreenReply), &rep);
return Success;
}
@@ -527,7 +526,7 @@ ProcDMXRemoveScreen(ClientPtr client)
swapl(&rep.length);
swapl(&rep.status);
}
- WriteToClient(client, sizeof(xDMXRemoveScreenReply), (char *) &rep);
+ WriteToClient(client, sizeof(xDMXRemoveScreenReply), &rep);
return Success;
}
@@ -663,12 +662,12 @@ ProcDMXGetWindowAttributes(ClientPtr client)
dmxFlushPendingSyncs();
- WriteToClient(client, sizeof(xDMXGetWindowAttributesReply), (char *) &rep);
+ WriteToClient(client, sizeof(xDMXGetWindowAttributesReply), &rep);
if (count) {
- WriteToClient(client, count * sizeof(*screens), (char *) screens);
- WriteToClient(client, count * sizeof(*windows), (char *) windows);
- WriteToClient(client, count * sizeof(*pos), (char *) pos);
- WriteToClient(client, count * sizeof(*vis), (char *) vis);
+ WriteToClient(client, count * sizeof(*screens), screens);
+ WriteToClient(client, count * sizeof(*windows), windows);
+ WriteToClient(client, count * sizeof(*pos), pos);
+ WriteToClient(client, count * sizeof(*vis), vis);
}
free(vis);
@@ -706,7 +705,7 @@ ProcDMXGetDesktopAttributes(ClientPtr client)
swaps(&rep.shiftX);
swaps(&rep.shiftY);
}
- WriteToClient(client, sizeof(xDMXGetDesktopAttributesReply), (char *) &rep);
+ WriteToClient(client, sizeof(xDMXGetDesktopAttributesReply), &rep);
return Success;
}
@@ -749,8 +748,7 @@ ProcDMXChangeDesktopAttributes(ClientPtr client)
swapl(&rep.length);
swapl(&rep.status);
}
- WriteToClient(client,
- sizeof(xDMXChangeDesktopAttributesReply), (char *) &rep);
+ WriteToClient(client, sizeof(xDMXChangeDesktopAttributesReply), &rep);
return Success;
}
@@ -770,7 +768,7 @@ ProcDMXGetInputCount(ClientPtr client)
swapl(&rep.length);
swapl(&rep.inputCount);
}
- WriteToClient(client, sizeof(xDMXGetInputCountReply), (char *) &rep);
+ WriteToClient(client, sizeof(xDMXGetInputCountReply), &rep);
return Success;
}
@@ -808,9 +806,9 @@ ProcDMXGetInputAttributes(ClientPtr client)
swapl(&rep.physicalId);
swapl(&rep.nameLength);
}
- WriteToClient(client, sizeof(xDMXGetInputAttributesReply), (char *) &rep);
+ WriteToClient(client, sizeof(xDMXGetInputAttributesReply), &rep);
if (length)
- WriteToClient(client, length, (char *) attr.name);
+ WriteToClient(client, length, attr.name);
return Success;
}
@@ -862,7 +860,7 @@ ProcDMXAddInput(ClientPtr client)
swapl(&rep.status);
swapl(&rep.physicalId);
}
- WriteToClient(client, sizeof(xDMXAddInputReply), (char *) &rep);
+ WriteToClient(client, sizeof(xDMXAddInputReply), &rep);
return Success;
}
@@ -889,7 +887,7 @@ ProcDMXRemoveInput(ClientPtr client)
swapl(&rep.length);
swapl(&rep.status);
}
- WriteToClient(client, sizeof(xDMXRemoveInputReply), (char *) &rep);
+ WriteToClient(client, sizeof(xDMXRemoveInputReply), &rep);
return Success;
}
diff --git a/hw/dmx/glxProxy/glxcmds.c b/hw/dmx/glxProxy/glxcmds.c
index 49c6ef1ed..32684faab 100644
--- a/hw/dmx/glxProxy/glxcmds.c
+++ b/hw/dmx/glxProxy/glxcmds.c
@@ -465,8 +465,7 @@ __glXQueryMaxSwapBarriersSGIX(__GLXclientState * cl, GLbyte * pc)
__glXSwapQueryMaxSwapBarriersSGIXReply(client, &reply);
}
else {
- WriteToClient(client, sz_xGLXQueryMaxSwapBarriersSGIXReply,
- (char *) &reply);
+ WriteToClient(client, sz_xGLXQueryMaxSwapBarriersSGIXReply, &reply);
}
return Success;
@@ -1388,8 +1387,7 @@ MakeCurrent(__GLXclientState * cl,
__glXSwapMakeCurrentReply(client, &new_reply);
}
else {
- WriteToClient(client, sz_xGLXMakeContextCurrentReply,
- (char *) &new_reply);
+ WriteToClient(client, sz_xGLXMakeContextCurrentReply, &new_reply);
}
return Success;
@@ -1449,7 +1447,7 @@ __glXIsDirect(__GLXclientState * cl, GLbyte * pc)
__glXSwapIsDirectReply(client, &reply);
}
else {
- WriteToClient(client, sz_xGLXIsDirectReply, (char *) &reply);
+ WriteToClient(client, sz_xGLXIsDirectReply, &reply);
}
return Success;
@@ -1478,7 +1476,7 @@ __glXQueryVersion(__GLXclientState * cl, GLbyte * pc)
__glXSwapQueryVersionReply(client, &reply);
}
else {
- WriteToClient(client, sz_xGLXQueryVersionReply, (char *) &reply);
+ WriteToClient(client, sz_xGLXQueryVersionReply, &reply);
}
return Success;
}
@@ -1689,7 +1687,7 @@ __glXGetVisualConfigs(__GLXclientState * cl, GLbyte * pc)
reply.type = X_Reply;
reply.sequenceNumber = client->sequence;
- WriteToClient(client, sz_xGLXGetVisualConfigsReply, (char *) &reply);
+ WriteToClient(client, sz_xGLXGetVisualConfigsReply, &reply);
for (i = 0; i < pGlxScreen->numVisuals; i++) {
pGlxVisual = &pGlxScreen->pGlxVisual[i];
@@ -1743,8 +1741,7 @@ __glXGetVisualConfigs(__GLXclientState * cl, GLbyte * pc)
buf[p++] = GLX_VISUAL_SELECT_GROUP_SGIX;
buf[p++] = pGlxVisual->visualSelectGroup;
- WriteToClient(client, __GLX_SIZE_CARD32 * __GLX_TOTAL_CONFIG,
- (char *) buf);
+ WriteToClient(client, __GLX_SIZE_CARD32 * __GLX_TOTAL_CONFIG, buf);
}
return Success;
}
@@ -2637,9 +2634,8 @@ __glXQueryExtensionsString(__GLXclientState * cl, GLbyte * pc)
glxSwapQueryExtensionsStringReply(client, &reply, be_buf);
}
else {
- WriteToClient(client, sz_xGLXQueryExtensionsStringReply,
- (char *) &reply);
- WriteToClient(client, (int) (length << 2), (char *) be_buf);
+ WriteToClient(client, sz_xGLXQueryExtensionsStringReply, &reply);
+ WriteToClient(client, (int) (length << 2), be_buf);
}
return Success;
@@ -2719,7 +2715,7 @@ __glXQueryServerString(__GLXclientState * cl, GLbyte * pc)
glxSwapQueryServerStringReply(client, &reply, be_buf);
}
else {
- WriteToClient(client, sz_xGLXQueryServerStringReply, (char *) &reply);
+ WriteToClient(client, sz_xGLXQueryServerStringReply, &reply);
WriteToClient(client, (int) (length << 2), be_buf);
}
@@ -2880,7 +2876,7 @@ __glXGetFBConfigs(__GLXclientState * cl, GLbyte * pc)
__GLX_SWAP_INT(&reply.numFBConfigs);
__GLX_SWAP_INT(&reply.numAttribs);
}
- WriteToClient(client, sz_xGLXGetFBConfigsReply, (char *) &reply);
+ WriteToClient(client, sz_xGLXGetFBConfigsReply, &reply);
for (i = 0; i < numFBConfigs; i++) {
int associatedVisualId = 0;
@@ -3021,7 +3017,7 @@ __glXGetFBConfigs(__GLXclientState * cl, GLbyte * pc)
__GLX_DECLARE_SWAP_ARRAY_VARIABLES;
__GLX_SWAP_INT_ARRAY((int *) buf, 2 * numAttribs);
}
- WriteToClient(client, 2 * numAttribs * __GLX_SIZE_CARD32, (char *) buf);
+ WriteToClient(client, 2 * numAttribs * __GLX_SIZE_CARD32, buf);
}
return Success;
}
@@ -3218,8 +3214,8 @@ __glXQueryContext(__GLXclientState * cl, GLbyte * pc)
__glXSwapQueryContextReply(client, &reply, sendBuf);
}
else {
- WriteToClient(client, sz_xGLXQueryContextReply, (char *) &reply);
- WriteToClient(client, nReplyBytes, (char *) sendBuf);
+ WriteToClient(client, sz_xGLXQueryContextReply, &reply);
+ WriteToClient(client, nReplyBytes, sendBuf);
}
free((char *) sendBuf);
@@ -3270,8 +3266,8 @@ __glXQueryContextInfoEXT(__GLXclientState * cl, GLbyte * pc)
__glXSwapQueryContextInfoEXTReply(client, &reply, sendBuf);
}
else {
- WriteToClient(client, sz_xGLXQueryContextInfoEXTReply, (char *) &reply);
- WriteToClient(client, nReplyBytes, (char *) sendBuf);
+ WriteToClient(client, sz_xGLXQueryContextInfoEXTReply, &reply);
+ WriteToClient(client, nReplyBytes, sendBuf);
}
free((char *) sendBuf);
@@ -3606,9 +3602,8 @@ __glXGetDrawableAttributes(__GLXclientState * cl, GLbyte * pc)
__glXSwapGetDrawableAttributesReply(client, &reply, (int *) attribs);
}
else {
- WriteToClient(client, sz_xGLXGetDrawableAttributesReply,
- (char *) &reply);
- WriteToClient(client, attribs_size, (char *) attribs);
+ WriteToClient(client, sz_xGLXGetDrawableAttributesReply, &reply);
+ WriteToClient(client, attribs_size, attribs);
}
free(attribs);
diff --git a/hw/dmx/glxProxy/glxcmdsswap.c b/hw/dmx/glxProxy/glxcmdsswap.c
index ec0e83d09..a11c9196f 100644
--- a/hw/dmx/glxProxy/glxcmdsswap.c
+++ b/hw/dmx/glxProxy/glxcmdsswap.c
@@ -304,7 +304,7 @@ __glXSwapGetVisualConfigs(__GLXclientState * cl, GLbyte * pc)
__GLX_SWAP_INT(&reply.length);
__GLX_SWAP_INT(&reply.numVisuals);
__GLX_SWAP_INT(&reply.numProps);
- WriteToClient(client, sz_xGLXGetVisualConfigsReply, (char *) &reply);
+ WriteToClient(client, sz_xGLXGetVisualConfigsReply, &reply);
for (i = 0; i < pGlxScreen->numVisuals; i++) {
pGlxVisual = &pGlxScreen->pGlxVisual[i];
@@ -353,8 +353,7 @@ __glXSwapGetVisualConfigs(__GLXclientState * cl, GLbyte * pc)
buf[p++] = pGlxVisual->transparentIndex;
__GLX_SWAP_INT_ARRAY(buf, __GLX_TOTAL_CONFIG);
- WriteToClient(client, __GLX_SIZE_CARD32 * __GLX_TOTAL_CONFIG,
- (char *) buf);
+ WriteToClient(client, __GLX_SIZE_CARD32 * __GLX_TOTAL_CONFIG, buf);
}
return Success;
}
@@ -508,7 +507,7 @@ __glXSwapMakeCurrentReply(ClientPtr client, xGLXMakeCurrentReadSGIReply * reply)
__GLX_SWAP_INT(&reply->writeType);
__GLX_SWAP_INT(&reply->readVid);
__GLX_SWAP_INT(&reply->readType);
- WriteToClient(client, sz_xGLXMakeCurrentReadSGIReply, (char *) reply);
+ WriteToClient(client, sz_xGLXMakeCurrentReadSGIReply, reply);
}
void
@@ -517,7 +516,7 @@ __glXSwapIsDirectReply(ClientPtr client, xGLXIsDirectReply * reply)
__GLX_DECLARE_SWAP_VARIABLES;
__GLX_SWAP_SHORT(&reply->sequenceNumber);
__GLX_SWAP_INT(&reply->length);
- WriteToClient(client, sz_xGLXIsDirectReply, (char *) reply);
+ WriteToClient(client, sz_xGLXIsDirectReply, reply);
}
void
@@ -528,7 +527,7 @@ __glXSwapQueryVersionReply(ClientPtr client, xGLXQueryVersionReply * reply)
__GLX_SWAP_INT(&reply->length);
__GLX_SWAP_INT(&reply->majorVersion);
__GLX_SWAP_INT(&reply->minorVersion);
- WriteToClient(client, sz_xGLXQueryVersionReply, (char *) reply);
+ WriteToClient(client, sz_xGLXQueryVersionReply, reply);
}
void
@@ -543,7 +542,7 @@ glxSwapQueryExtensionsStringReply(ClientPtr client,
__GLX_SWAP_SHORT(&reply->sequenceNumber);
__GLX_SWAP_INT(&reply->length);
__GLX_SWAP_INT(&reply->n);
- WriteToClient(client, sz_xGLXQueryExtensionsStringReply, (char *) reply);
+ WriteToClient(client, sz_xGLXQueryExtensionsStringReply, reply);
__GLX_SWAP_INT_ARRAY((int *) buf, length);
WriteToClient(client, length << 2, buf);
}
@@ -558,7 +557,7 @@ glxSwapQueryServerStringReply(ClientPtr client,
__GLX_SWAP_SHORT(&reply->sequenceNumber);
__GLX_SWAP_INT(&reply->length);
__GLX_SWAP_INT(&reply->n);
- WriteToClient(client, sz_xGLXQueryServerStringReply, (char *) reply);
+ WriteToClient(client, sz_xGLXQueryServerStringReply, reply);
/** no swap is needed for an array of chars **/
/* __GLX_SWAP_INT_ARRAY((int *)buf, length); */
WriteToClient(client, length << 2, buf);
@@ -576,9 +575,9 @@ __glXSwapQueryContextInfoEXTReply(ClientPtr client,
__GLX_SWAP_SHORT(&reply->sequenceNumber);
__GLX_SWAP_INT(&reply->length);
__GLX_SWAP_INT(&reply->n);
- WriteToClient(client, sz_xGLXQueryContextInfoEXTReply, (char *) reply);
+ WriteToClient(client, sz_xGLXQueryContextInfoEXTReply, reply);
__GLX_SWAP_INT_ARRAY((int *) buf, length);
- WriteToClient(client, length << 2, (char *) buf);
+ WriteToClient(client, length << 2, buf);
}
void
@@ -592,9 +591,9 @@ __glXSwapQueryContextReply(ClientPtr client,
__GLX_SWAP_SHORT(&reply->sequenceNumber);
__GLX_SWAP_INT(&reply->length);
__GLX_SWAP_INT(&reply->n);
- WriteToClient(client, sz_xGLXQueryContextReply, (char *) reply);
+ WriteToClient(client, sz_xGLXQueryContextReply, reply);
__GLX_SWAP_INT_ARRAY((int *) buf, length);
- WriteToClient(client, length << 2, (char *) buf);
+ WriteToClient(client, length << 2, buf);
}
void
@@ -608,8 +607,8 @@ __glXSwapGetDrawableAttributesReply(ClientPtr client,
__GLX_SWAP_INT(&reply->length);
__GLX_SWAP_INT(&reply->numAttribs);
__GLX_SWAP_INT_ARRAY(buf, reply->length);
- WriteToClient(client, sz_xGLXGetDrawableAttributesReply, (char *) reply);
- WriteToClient(client, reply->length << 2, (char *) buf);
+ WriteToClient(client, sz_xGLXGetDrawableAttributesReply, reply);
+ WriteToClient(client, reply->length << 2, buf);
}
void
@@ -621,7 +620,7 @@ __glXSwapQueryMaxSwapBarriersSGIXReply(ClientPtr client,
__GLX_SWAP_SHORT(&reply->sequenceNumber);
__GLX_SWAP_INT(&reply->length);
__GLX_SWAP_INT(&reply->max);
- WriteToClient(client, sz_xGLXQueryMaxSwapBarriersSGIXReply, (char *) reply);
+ WriteToClient(client, sz_xGLXQueryMaxSwapBarriersSGIXReply, reply);
}
/************************************************************************/
diff --git a/hw/dmx/glxProxy/glxsingle.c b/hw/dmx/glxProxy/glxsingle.c
index 63786cf79..2253060b8 100644
--- a/hw/dmx/glxProxy/glxsingle.c
+++ b/hw/dmx/glxProxy/glxsingle.c
@@ -147,9 +147,9 @@ SendSwappedReply(ClientPtr client,
}
- WriteToClient(client, sizeof(xGLXSingleReply), (char *) reply);
+ WriteToClient(client, sizeof(xGLXSingleReply), reply);
if (buf_size > 0)
- WriteToClient(client, buf_size, (char *) buf);
+ WriteToClient(client, buf_size, buf);
}
@@ -281,9 +281,9 @@ __glXForwardPipe0WithReply(__GLXclientState * cl, GLbyte * pc)
SendSwappedReply(client, &reply, be_buf, be_buf_size);
}
else {
- WriteToClient(client, sizeof(xGLXSingleReply), (char *) &reply);
+ WriteToClient(client, sizeof(xGLXSingleReply), &reply);
if (be_buf_size > 0)
- WriteToClient(client, be_buf_size, (char *) be_buf);
+ WriteToClient(client, be_buf_size, be_buf);
}
if (be_buf_size > 0)
@@ -383,9 +383,9 @@ __glXForwardAllWithReply(__GLXclientState * cl, GLbyte * pc)
SendSwappedReply(client, &reply, be_buf, be_buf_size);
}
else {
- WriteToClient(client, sizeof(xGLXSingleReply), (char *) &reply);
+ WriteToClient(client, sizeof(xGLXSingleReply), &reply);
if (be_buf_size > 0)
- WriteToClient(client, be_buf_size, (char *) be_buf);
+ WriteToClient(client, be_buf_size, be_buf);
}
if (be_buf_size > 0)
@@ -1013,9 +1013,9 @@ __glXDisp_ReadPixels(__GLXclientState * cl, GLbyte * pc)
__GLX_SWAP_INT(&reply.length);
}
- WriteToClient(client, sizeof(xGLXReadPixelsReply), (char *) &reply);
+ WriteToClient(client, sizeof(xGLXReadPixelsReply), &reply);
if (buf_size > 0) {
- WriteToClient(client, buf_size, (char *) buf);
+ WriteToClient(client, buf_size, buf);
free(buf);
}
diff --git a/hw/dmx/glxProxy/glxvendor.c b/hw/dmx/glxProxy/glxvendor.c
index 963c92e87..e5c8da144 100644
--- a/hw/dmx/glxProxy/glxvendor.c
+++ b/hw/dmx/glxProxy/glxvendor.c
@@ -138,9 +138,9 @@ SendSwappedReply(ClientPtr client,
}
- WriteToClient(client, sizeof(xGLXVendorPrivReply), (char *) reply);
+ WriteToClient(client, sizeof(xGLXVendorPrivReply), reply);
if (buf_size > 0)
- WriteToClient(client, buf_size, (char *) buf);
+ WriteToClient(client, buf_size, buf);
}
@@ -265,9 +265,9 @@ __glXVForwardPipe0WithReply(__GLXclientState * cl, GLbyte * pc)
SendSwappedReply(client, &reply, be_buf, be_buf_size);
}
else {
- WriteToClient(client, sizeof(xGLXVendorPrivReply), (char *) &reply);
+ WriteToClient(client, sizeof(xGLXVendorPrivReply), &reply);
if (be_buf_size > 0)
- WriteToClient(client, be_buf_size, (char *) be_buf);
+ WriteToClient(client, be_buf_size, be_buf);
}
if (be_buf_size > 0)
@@ -364,9 +364,9 @@ __glXVForwardAllWithReply(__GLXclientState * cl, GLbyte * pc)
SendSwappedReply(client, &reply, be_buf, be_buf_size);
}
else {
- WriteToClient(client, sizeof(xGLXVendorPrivReply), (char *) &reply);
+ WriteToClient(client, sizeof(xGLXVendorPrivReply), &reply);
if (be_buf_size > 0)
- WriteToClient(client, be_buf_size, (char *) be_buf);
+ WriteToClient(client, be_buf_size, be_buf);
}
if (be_buf_size > 0)
diff --git a/hw/dmx/glxProxy/unpack.h b/hw/dmx/glxProxy/unpack.h
index b4b73580c..45c27c6b9 100644
--- a/hw/dmx/glxProxy/unpack.h
+++ b/hw/dmx/glxProxy/unpack.h
@@ -59,7 +59,7 @@ extern xGLXSingleReply __glXReply;
__glXReply.sequenceNumber = client->sequence;
#define __GLX_SEND_HEADER() \
- WriteToClient( client, sz_xGLXSingleReply, (char *)&__glXReply);
+ WriteToClient (client, sz_xGLXSingleReply, &__glXReply);
#define __GLX_PUT_RETVAL(a) \
__glXReply.retval = (a);
@@ -112,19 +112,19 @@ extern xGLXSingleReply __glXReply;
*(GLdouble *)&__glXReply.pad3 = *(GLdouble *)answer
#define __GLX_SEND_BYTE_ARRAY(len) \
- WriteToClient(client, __GLX_PAD((len)*__GLX_SIZE_INT8), (char *)answer)
+ WriteToClient(client, __GLX_PAD((len)*__GLX_SIZE_INT8), answer)
#define __GLX_SEND_SHORT_ARRAY(len) \
- WriteToClient(client, __GLX_PAD((len)*__GLX_SIZE_INT16), (char *)answer)
+ WriteToClient(client, __GLX_PAD((len)*__GLX_SIZE_INT16), answer)
#define __GLX_SEND_INT_ARRAY(len) \
- WriteToClient(client, (len)*__GLX_SIZE_INT32, (char *)answer)
+ WriteToClient(client, (len)*__GLX_SIZE_INT32, answer)
#define __GLX_SEND_FLOAT_ARRAY(len) \
- WriteToClient(client, (len)*__GLX_SIZE_FLOAT32, (char *)answer)
+ WriteToClient(client, (len)*__GLX_SIZE_FLOAT32, answer)
#define __GLX_SEND_DOUBLE_ARRAY(len) \
- WriteToClient(client, (len)*__GLX_SIZE_FLOAT64, (char *)answer)
+ WriteToClient(client, (len)*__GLX_SIZE_FLOAT64, answer)
#define __GLX_SEND_VOID_ARRAY(len) __GLX_SEND_BYTE_ARRAY(len)
#define __GLX_SEND_UBYTE_ARRAY(len) __GLX_SEND_BYTE_ARRAY(len)
diff --git a/hw/kdrive/ephyr/ephyrdriext.c b/hw/kdrive/ephyr/ephyrdriext.c
index 28486f516..aefbcfbce 100644
--- a/hw/kdrive/ephyr/ephyrdriext.c
+++ b/hw/kdrive/ephyr/ephyrdriext.c
@@ -536,7 +536,7 @@ ProcXF86DRIQueryVersion(register ClientPtr client)
swaps(&rep.minorVersion);
swapl(&rep.patchVersion);
}
- WriteToClient(client, sizeof(xXF86DRIQueryVersionReply), (char *) &rep);
+ WriteToClient(client, sizeof(xXF86DRIQueryVersionReply), &rep);
EPHYR_LOG("leave\n");
return Success;
}
@@ -574,7 +574,7 @@ ProcXF86DRIQueryDirectRenderingCapable(register ClientPtr client)
}
WriteToClient(client, sizeof(xXF86DRIQueryDirectRenderingCapableReply),
- (char *) &rep);
+ &rep);
EPHYR_LOG("leave\n");
return Success;
@@ -617,7 +617,7 @@ ProcXF86DRIOpenConnection(register ClientPtr client)
rep.hSAREAHigh = 0;
#endif
- WriteToClient(client, sizeof(xXF86DRIOpenConnectionReply), (char *) &rep);
+ WriteToClient(client, sizeof(xXF86DRIOpenConnectionReply), &rep);
if (rep.busIdStringLength)
WriteToClient(client, rep.busIdStringLength, busIdString);
free(busIdString);
@@ -648,7 +648,7 @@ ProcXF86DRIAuthConnection(register ClientPtr client)
ErrorF("Failed to authenticate %lu\n", (unsigned long) stuff->magic);
rep.authenticated = 0;
}
- WriteToClient(client, sizeof(xXF86DRIAuthConnectionReply), (char *) &rep);
+ WriteToClient(client, sizeof(xXF86DRIAuthConnectionReply), &rep);
EPHYR_LOG("leave\n");
return Success;
}
@@ -702,8 +702,7 @@ ProcXF86DRIGetClientDriverName(register ClientPtr client)
SIZEOF(xGenericReply) +
pad_to_int32(rep.clientDriverNameLength));
- WriteToClient(client,
- sizeof(xXF86DRIGetClientDriverNameReply), (char *) &rep);
+ WriteToClient(client, sizeof(xXF86DRIGetClientDriverNameReply), &rep);
if (rep.clientDriverNameLength)
WriteToClient(client, rep.clientDriverNameLength, clientDriverName);
EPHYR_LOG("leave\n");
@@ -752,7 +751,7 @@ ProcXF86DRICreateContext(register ClientPtr client)
return BadValue;
}
- WriteToClient(client, sizeof(xXF86DRICreateContextReply), (char *) &rep);
+ WriteToClient(client, sizeof(xXF86DRICreateContextReply), &rep);
EPHYR_LOG("leave\n");
return Success;
}
@@ -974,7 +973,7 @@ ProcXF86DRICreateDrawable(ClientPtr client)
EPHYR_LOG("paired window '%p' with remote '%d'\n", window, remote_win);
}
- WriteToClient(client, sizeof(xXF86DRICreateDrawableReply), (char *) &rep);
+ WriteToClient(client, sizeof(xXF86DRICreateDrawableReply), &rep);
EPHYR_LOG("leave\n");
return Success;
}
@@ -1136,18 +1135,18 @@ ProcXF86DRIGetDrawableInfo(register ClientPtr client)
rep.length = bytes_to_int32(rep.length);
- WriteToClient(client, sizeof(xXF86DRIGetDrawableInfoReply), (char *) &rep);
+ WriteToClient(client, sizeof(xXF86DRIGetDrawableInfoReply), &rep);
if (rep.numClipRects) {
WriteToClient(client,
sizeof(drm_clip_rect_t) * rep.numClipRects,
- (char *) clipRects);
+ clipRects);
}
if (rep.numBackClipRects) {
WriteToClient(client,
sizeof(drm_clip_rect_t) * rep.numBackClipRects,
- (char *) backClipRects);
+ backClipRects);
}
free(clipRects);
clipRects = NULL;
@@ -1200,9 +1199,9 @@ ProcXF86DRIGetDeviceInfo(register ClientPtr client)
pad_to_int32(rep.devPrivateSize));
}
- WriteToClient(client, sizeof(xXF86DRIGetDeviceInfoReply), (char *) &rep);
+ WriteToClient(client, sizeof(xXF86DRIGetDeviceInfoReply), &rep);
if (rep.length) {
- WriteToClient(client, rep.devPrivateSize, (char *) pDevPrivate);
+ WriteToClient(client, rep.devPrivateSize, pDevPrivate);
}
EPHYR_LOG("leave\n");
return Success;
diff --git a/hw/kdrive/ephyr/ephyrglxext.c b/hw/kdrive/ephyr/ephyrglxext.c
index dab028bf3..1287e0484 100644
--- a/hw/kdrive/ephyr/ephyrglxext.c
+++ b/hw/kdrive/ephyr/ephyrglxext.c
@@ -169,7 +169,7 @@ ephyrGLXQueryVersion(__GLXclientState * a_cl, GLbyte * a_pc)
__glXSwapQueryVersionReply(client, &reply);
}
else {
- WriteToClient(client, sz_xGLXQueryVersionReply, (char *) &reply);
+ WriteToClient(client, sz_xGLXQueryVersionReply, &reply);
}
res = Success;
@@ -228,7 +228,7 @@ ephyrGLXGetVisualConfigsReal(__GLXclientState * a_cl,
__GLX_SWAP_INT(&reply.numProps);
__GLX_SWAP_INT_ARRAY(props_buf, num_props);
}
- WriteToClient(client, sz_xGLXGetVisualConfigsReply, (char *) &reply);
+ WriteToClient(client, sz_xGLXGetVisualConfigsReply, &reply);
props_per_visual_size = props_buf_size / num_visuals;
for (i = 0; i < num_visuals; i++) {
WriteToClient(client,
@@ -282,7 +282,7 @@ ephyrGLXGetFBConfigsSGIXReal(__GLXclientState * a_cl,
__GLX_SWAP_INT(&reply.numProps);
__GLX_SWAP_INT_ARRAY(props_buf, num_props);
}
- WriteToClient(client, sz_xGLXGetVisualConfigsReply, (char *) &reply);
+ WriteToClient(client, sz_xGLXGetVisualConfigsReply, &reply);
props_per_visual_size = props_buf_size / num_visuals;
for (i = 0; i < num_visuals; i++) {
WriteToClient(client,
@@ -375,7 +375,7 @@ ephyrGLXQueryServerString(__GLXclientState * a_cl, GLbyte * a_pc)
}
memcpy(buf, server_string, length);
- WriteToClient(client, sz_xGLXQueryServerStringReply, (char *) &reply);
+ WriteToClient(client, sz_xGLXQueryServerStringReply, &reply);
WriteToClient(client, (int) (reply.length << 2), server_string);
res = Success;
@@ -538,7 +538,7 @@ ephyrGLXMakeCurrentReal(__GLXclientState * a_cl, GLbyte * a_pc, Bool a_do_swap)
__GLX_SWAP_INT(&reply.length);
__GLX_SWAP_INT(&reply.contextTag);
}
- WriteToClient(a_cl->client, sz_xGLXMakeCurrentReply, (char *) &reply);
+ WriteToClient(a_cl->client, sz_xGLXMakeCurrentReply, &reply);
res = Success;
out:
@@ -601,7 +601,7 @@ ephyrGLXGetStringReal(__GLXclientState * a_cl, GLbyte * a_pc, Bool a_do_swap)
__GLX_SWAP_REPLY_SIZE();
__GLX_SWAP_REPLY_HEADER();
}
- WriteToClient(client, length, (char *) string);
+ WriteToClient(client, length, string);
res = Success;
out:
@@ -690,7 +690,7 @@ ephyrGLXIsDirectReal(__GLXclientState * a_cl, GLbyte * a_pc, Bool a_do_swap)
reply.length = 0;
reply.type = X_Reply;
reply.sequenceNumber = client->sequence;
- WriteToClient(client, sz_xGLXIsDirectReply, (char *) &reply);
+ WriteToClient(client, sz_xGLXIsDirectReply, &reply);
res = Success;
out:
diff --git a/hw/kdrive/ephyr/ephyrproxyext.c b/hw/kdrive/ephyr/ephyrproxyext.c
index 3d86d2db1..c24238c04 100644
--- a/hw/kdrive/ephyr/ephyrproxyext.c
+++ b/hw/kdrive/ephyr/ephyrproxyext.c
@@ -75,7 +75,7 @@ ephyrProxyProcDispatch(ClientPtr a_client)
reply.sequence_number = a_client->sequence;
res = Success;
- WriteToClient(a_client, 32, (char *) &reply);
+ WriteToClient(a_client, 32, &reply);
out:
return res;
diff --git a/hw/xfree86/dixmods/extmod/xf86dga2.c b/hw/xfree86/dixmods/extmod/xf86dga2.c
index 6b33941ef..1ed6a50b2 100644
--- a/hw/xfree86/dixmods/extmod/xf86dga2.c
+++ b/hw/xfree86/dixmods/extmod/xf86dga2.c
@@ -84,7 +84,7 @@ ProcXDGAQueryVersion(ClientPtr client)
rep.majorVersion = SERVER_XDGA_MAJOR_VERSION;
rep.minorVersion = SERVER_XDGA_MINOR_VERSION;
- WriteToClient(client, sizeof(xXDGAQueryVersionReply), (char *) &rep);
+ WriteToClient(client, sizeof(xXDGAQueryVersionReply), &rep);
return Success;
}
@@ -117,7 +117,7 @@ ProcXDGAOpenFramebuffer(ClientPtr client)
nameSize = deviceName ? (strlen(deviceName) + 1) : 0;
rep.length = bytes_to_int32(nameSize);
- WriteToClient(client, sizeof(xXDGAOpenFramebufferReply), (char *) &rep);
+ WriteToClient(client, sizeof(xXDGAOpenFramebufferReply), &rep);
if (rep.length)
WriteToClient(client, nameSize, deviceName);
@@ -164,12 +164,12 @@ ProcXDGAQueryModes(ClientPtr client)
if (!DGAAvailable(stuff->screen)) {
rep.number = 0;
rep.length = 0;
- WriteToClient(client, sz_xXDGAQueryModesReply, (char *) &rep);
+ WriteToClient(client, sz_xXDGAQueryModesReply, &rep);
return Success;
}
if (!(num = DGAGetModes(stuff->screen))) {
- WriteToClient(client, sz_xXDGAQueryModesReply, (char *) &rep);
+ WriteToClient(client, sz_xXDGAQueryModesReply, &rep);
return Success;
}
@@ -186,7 +186,7 @@ ProcXDGAQueryModes(ClientPtr client)
rep.number = num;
rep.length = bytes_to_int32(size);
- WriteToClient(client, sz_xXDGAQueryModesReply, (char *) &rep);
+ WriteToClient(client, sz_xXDGAQueryModesReply, &rep);
for (i = 0; i < num; i++) {
size = strlen(mode[i].name) + 1;
@@ -218,7 +218,7 @@ ProcXDGAQueryModes(ClientPtr client)
info.reserved1 = mode[i].reserved1;
info.reserved2 = mode[i].reserved2;
- WriteToClient(client, sz_xXDGAModeInfo, (char *) (&info));
+ WriteToClient(client, sz_xXDGAModeInfo, (&info));
WriteToClient(client, size, mode[i].name);
}
@@ -293,7 +293,7 @@ ProcXDGASetMode(ClientPtr client)
DGA_SETCLIENT(stuff->screen, NULL);
DGASelectInput(stuff->screen, NULL, 0);
DGASetMode(stuff->screen, 0, &mode, &pPix);
- WriteToClient(client, sz_xXDGASetModeReply, (char *) &rep);
+ WriteToClient(client, sz_xXDGASetModeReply, &rep);
return Success;
}
@@ -345,8 +345,8 @@ ProcXDGASetMode(ClientPtr client)
rep.length = bytes_to_int32(sz_xXDGAModeInfo + info.name_size);
- WriteToClient(client, sz_xXDGASetModeReply, (char *) &rep);
- WriteToClient(client, sz_xXDGAModeInfo, (char *) (&info));
+ WriteToClient(client, sz_xXDGASetModeReply, &rep);
+ WriteToClient(client, sz_xXDGAModeInfo, (&info));
WriteToClient(client, size, mode.name);
return Success;
@@ -494,7 +494,7 @@ ProcXDGAGetViewportStatus(ClientPtr client)
rep.status = DGAGetViewportStatus(stuff->screen);
- WriteToClient(client, sizeof(xXDGAGetViewportStatusReply), (char *) &rep);
+ WriteToClient(client, sizeof(xXDGAGetViewportStatusReply), &rep);
return Success;
}
@@ -517,7 +517,7 @@ ProcXDGASync(ClientPtr client)
DGASync(stuff->screen);
- WriteToClient(client, sizeof(xXDGASyncReply), (char *) &rep);
+ WriteToClient(client, sizeof(xXDGASyncReply), &rep);
return Success;
}
@@ -568,7 +568,7 @@ ProcXDGAChangePixmapMode(ClientPtr client)
rep.x = x;
rep.y = y;
- WriteToClient(client, sizeof(xXDGAChangePixmapModeReply), (char *) &rep);
+ WriteToClient(client, sizeof(xXDGAChangePixmapModeReply), &rep);
return Success;
}
@@ -641,7 +641,7 @@ ProcXF86DGAGetVideoLL(ClientPtr client)
rep.width = mode.bytesPerScanline / (mode.bitsPerPixel >> 3);
rep.ram_size = rep.bank_size >> 10;
- WriteToClient(client, SIZEOF(xXF86DGAGetVideoLLReply), (char *) &rep);
+ WriteToClient(client, SIZEOF(xXF86DGAGetVideoLLReply), &rep);
return Success;
}
@@ -732,7 +732,7 @@ ProcXF86DGAGetViewPortSize(ClientPtr client)
rep.width = mode.viewportWidth;
rep.height = mode.viewportHeight;
- WriteToClient(client, SIZEOF(xXF86DGAGetViewPortSizeReply), (char *) &rep);
+ WriteToClient(client, SIZEOF(xXF86DGAGetViewPortSizeReply), &rep);
return Success;
}
@@ -777,7 +777,7 @@ ProcXF86DGAGetVidPage(ClientPtr client)
rep.sequenceNumber = client->sequence;
rep.vpage = 0; /* silently fail */
- WriteToClient(client, SIZEOF(xXF86DGAGetVidPageReply), (char *) &rep);
+ WriteToClient(client, SIZEOF(xXF86DGAGetVidPageReply), &rep);
return Success;
}
@@ -844,7 +844,7 @@ ProcXF86DGAQueryDirectVideo(ClientPtr client)
if (DGAAvailable(stuff->screen))
rep.flags = XF86DGADirectPresent;
- WriteToClient(client, SIZEOF(xXF86DGAQueryDirectVideoReply), (char *) &rep);
+ WriteToClient(client, SIZEOF(xXF86DGAQueryDirectVideoReply), &rep);
return Success;
}
@@ -870,7 +870,7 @@ ProcXF86DGAViewPortChanged(ClientPtr client)
rep.sequenceNumber = client->sequence;
rep.result = 1;
- WriteToClient(client, SIZEOF(xXF86DGAViewPortChangedReply), (char *) &rep);
+ WriteToClient(client, SIZEOF(xXF86DGAViewPortChangedReply), &rep);
return Success;
}
diff --git a/hw/xfree86/dixmods/extmod/xf86vmode.c b/hw/xfree86/dixmods/extmod/xf86vmode.c
index 68c4b583f..bd23dc25f 100644
--- a/hw/xfree86/dixmods/extmod/xf86vmode.c
+++ b/hw/xfree86/dixmods/extmod/xf86vmode.c
@@ -296,7 +296,7 @@ ProcXF86VidModeQueryVersion(ClientPtr client)
swaps(&rep.majorVersion);
swaps(&rep.minorVersion);
}
- WriteToClient(client, sizeof(xXF86VidModeQueryVersionReply), (char *) &rep);
+ WriteToClient(client, sizeof(xXF86VidModeQueryVersionReply), &rep);
return Success;
}
@@ -391,12 +391,10 @@ ProcXF86VidModeGetModeLine(ClientPtr client)
oldrep.vtotal = rep.vtotal;
oldrep.flags = rep.flags;
oldrep.privsize = rep.privsize;
- WriteToClient(client, sizeof(xXF86OldVidModeGetModeLineReply),
- (char *) &oldrep);
+ WriteToClient(client, sizeof(xXF86OldVidModeGetModeLineReply), &oldrep);
}
else {
- WriteToClient(client, sizeof(xXF86VidModeGetModeLineReply),
- (char *) &rep);
+ WriteToClient(client, sizeof(xXF86VidModeGetModeLineReply), &rep);
}
return Success;
}
@@ -443,8 +441,7 @@ ProcXF86VidModeGetAllModeLines(ClientPtr client)
swapl(&rep.length);
swapl(&rep.modecount);
}
- WriteToClient(client, sizeof(xXF86VidModeGetAllModeLinesReply),
- (char *) &rep);
+ WriteToClient(client, sizeof(xXF86VidModeGetAllModeLinesReply), &rep);
do {
mdinf.dotclock = dotClock;
@@ -485,12 +482,10 @@ ProcXF86VidModeGetAllModeLines(ClientPtr client)
oldmdinf.vtotal = mdinf.vtotal;
oldmdinf.flags = mdinf.flags;
oldmdinf.privsize = mdinf.privsize;
- WriteToClient(client, sizeof(xXF86OldVidModeModeInfo),
- (char *) &oldmdinf);
+ WriteToClient(client, sizeof(xXF86OldVidModeModeInfo), &oldmdinf);
}
else {
- WriteToClient(client, sizeof(xXF86VidModeModeInfo),
- (char *) &mdinf);
+ WriteToClient(client, sizeof(xXF86VidModeModeInfo), &mdinf);
}
} while (VidModeGetNextModeline(stuff->screen, &mode, &dotClock));
@@ -1040,8 +1035,7 @@ ProcXF86VidModeValidateModeLine(ClientPtr client)
swapl(&rep.length);
swapl(&rep.status);
}
- WriteToClient(client, sizeof(xXF86VidModeValidateModeLineReply),
- (char *) &rep);
+ WriteToClient(client, sizeof(xXF86VidModeValidateModeLineReply), &rep);
if (xf86GetVerbosity() > DEFAULT_XF86VIDMODE_VERBOSITY)
ErrorF("ValidateModeLine - Succeeded (status = %d)\n", status);
return Success;
@@ -1262,20 +1256,16 @@ ProcXF86VidModeGetMonitor(ClientPtr client)
swaps(&rep.sequenceNumber);
swapl(&rep.length);
}
- WriteToClient(client, SIZEOF(xXF86VidModeGetMonitorReply), (char *) &rep);
+ WriteToClient(client, SIZEOF(xXF86VidModeGetMonitorReply), &rep);
client->pSwapReplyFunc = (ReplySwapPtr) Swap32Write;
WriteSwappedDataToClient(client, nHsync * sizeof(CARD32), hsyncdata);
WriteSwappedDataToClient(client, nVrefresh * sizeof(CARD32), vsyncdata);
if (rep.vendorLength)
WriteToClient(client, rep.vendorLength,
- (char
- *) (VidModeGetMonitorValue(monitor, VIDMODE_MON_VENDOR,
- 0)).ptr);
+ (VidModeGetMonitorValue(monitor, VIDMODE_MON_VENDOR, 0)).ptr);
if (rep.modelLength)
WriteToClient(client, rep.modelLength,
- (char
- *) (VidModeGetMonitorValue(monitor, VIDMODE_MON_MODEL,
- 0)).ptr);
+ (VidModeGetMonitorValue(monitor, VIDMODE_MON_MODEL, 0)).ptr);
free(hsyncdata);
free(vsyncdata);
@@ -1311,7 +1301,7 @@ ProcXF86VidModeGetViewPort(ClientPtr client)
swapl(&rep.x);
swapl(&rep.y);
}
- WriteToClient(client, SIZEOF(xXF86VidModeGetViewPortReply), (char *) &rep);
+ WriteToClient(client, SIZEOF(xXF86VidModeGetViewPortReply), &rep);
return Success;
}
@@ -1380,7 +1370,7 @@ ProcXF86VidModeGetDotClocks(ClientPtr client)
swapl(&rep.maxclocks);
swapl(&rep.flags);
}
- WriteToClient(client, sizeof(xXF86VidModeGetDotClocksReply), (char *) &rep);
+ WriteToClient(client, sizeof(xXF86VidModeGetDotClocksReply), &rep);
if (!ClockProg) {
for (n = 0; n < numClocks; n++) {
dotclock = *Clocks++;
@@ -1388,7 +1378,7 @@ ProcXF86VidModeGetDotClocks(ClientPtr client)
WriteSwappedDataToClient(client, 4, (char *) &dotclock);
}
else {
- WriteToClient(client, 4, (char *) &dotclock);
+ WriteToClient(client, 4, &dotclock);
}
}
}
@@ -1446,7 +1436,7 @@ ProcXF86VidModeGetGamma(ClientPtr client)
swapl(&rep.green);
swapl(&rep.blue);
}
- WriteToClient(client, sizeof(xXF86VidModeGetGammaReply), (char *) &rep);
+ WriteToClient(client, sizeof(xXF86VidModeGetGammaReply), &rep);
return Success;
}
@@ -1520,10 +1510,10 @@ ProcXF86VidModeGetGammaRamp(ClientPtr client)
swaps(&rep.size);
SwapShorts((short *) ramp, length * 3);
}
- WriteToClient(client, sizeof(xXF86VidModeGetGammaRampReply), (char *) &rep);
+ WriteToClient(client, sizeof(xXF86VidModeGetGammaRampReply), &rep);
if (stuff->size) {
- WriteToClient(client, ramplen, (char *) ramp);
+ WriteToClient(client, ramplen, ramp);
free(ramp);
}
@@ -1551,8 +1541,7 @@ ProcXF86VidModeGetGammaRampSize(ClientPtr client)
swapl(&rep.length);
swaps(&rep.size);
}
- WriteToClient(client, sizeof(xXF86VidModeGetGammaRampSizeReply),
- (char *) &rep);
+ WriteToClient(client, sizeof(xXF86VidModeGetGammaRampSizeReply), &rep);
return Success;
}
@@ -1582,8 +1571,7 @@ ProcXF86VidModeGetPermissions(ClientPtr client)
swapl(&rep.length);
swapl(&rep.permissions);
}
- WriteToClient(client, sizeof(xXF86VidModeGetPermissionsReply),
- (char *) &rep);
+ WriteToClient(client, sizeof(xXF86VidModeGetPermissionsReply), &rep);
return Success;
}
diff --git a/hw/xfree86/dri/xf86dri.c b/hw/xfree86/dri/xf86dri.c
index 72ce8690d..ee7b21311 100644
--- a/hw/xfree86/dri/xf86dri.c
+++ b/hw/xfree86/dri/xf86dri.c
@@ -94,7 +94,7 @@ ProcXF86DRIQueryVersion(register ClientPtr client)
swaps(&rep.minorVersion);
swapl(&rep.patchVersion);
}
- WriteToClient(client, sizeof(xXF86DRIQueryVersionReply), (char *) &rep);
+ WriteToClient(client, sizeof(xXF86DRIQueryVersionReply), &rep);
return Success;
}
@@ -131,7 +131,7 @@ ProcXF86DRIQueryDirectRenderingCapable(register ClientPtr client)
WriteToClient(client,
sizeof(xXF86DRIQueryDirectRenderingCapableReply),
- (char *) &rep);
+ &rep);
return Success;
}
@@ -171,7 +171,7 @@ ProcXF86DRIOpenConnection(register ClientPtr client)
rep.hSAREAHigh = 0;
#endif
- WriteToClient(client, sizeof(xXF86DRIOpenConnectionReply), (char *) &rep);
+ WriteToClient(client, sizeof(xXF86DRIOpenConnectionReply), &rep);
if (rep.busIdStringLength)
WriteToClient(client, rep.busIdStringLength, busIdString);
return Success;
@@ -198,7 +198,7 @@ ProcXF86DRIAuthConnection(register ClientPtr client)
ErrorF("Failed to authenticate %lu\n", (unsigned long) stuff->magic);
rep.authenticated = 0;
}
- WriteToClient(client, sizeof(xXF86DRIAuthConnectionReply), (char *) &rep);
+ WriteToClient(client, sizeof(xXF86DRIAuthConnectionReply), &rep);
return Success;
}
@@ -245,8 +245,7 @@ ProcXF86DRIGetClientDriverName(register ClientPtr client)
SIZEOF(xGenericReply) +
pad_to_int32(rep.clientDriverNameLength));
- WriteToClient(client,
- sizeof(xXF86DRIGetClientDriverNameReply), (char *) &rep);
+ WriteToClient(client, sizeof(xXF86DRIGetClientDriverNameReply), &rep);
if (rep.clientDriverNameLength)
WriteToClient(client, rep.clientDriverNameLength, clientDriverName);
return Success;
@@ -277,7 +276,7 @@ ProcXF86DRICreateContext(register ClientPtr client)
return BadValue;
}
- WriteToClient(client, sizeof(xXF86DRICreateContextReply), (char *) &rep);
+ WriteToClient(client, sizeof(xXF86DRICreateContextReply), &rep);
return Success;
}
@@ -326,7 +325,7 @@ ProcXF86DRICreateDrawable(ClientPtr client)
return BadValue;
}
- WriteToClient(client, sizeof(xXF86DRICreateDrawableReply), (char *) &rep);
+ WriteToClient(client, sizeof(xXF86DRICreateDrawableReply), &rep);
return Success;
}
@@ -444,19 +443,19 @@ ProcXF86DRIGetDrawableInfo(register ClientPtr client)
rep.length = bytes_to_int32(rep.length);
- WriteToClient(client, sizeof(xXF86DRIGetDrawableInfoReply), (char *) &rep);
+ WriteToClient(client, sizeof(xXF86DRIGetDrawableInfoReply), &rep);
if (rep.numClipRects) {
WriteToClient(client,
sizeof(drm_clip_rect_t) * rep.numClipRects,
- (char *) pClippedRects);
+ pClippedRects);
free(pClippedRects);
}
if (rep.numBackClipRects) {
WriteToClient(client,
sizeof(drm_clip_rect_t) * rep.numBackClipRects,
- (char *) pBackClipRects);
+ pBackClipRects);
}
return Success;
@@ -503,9 +502,9 @@ ProcXF86DRIGetDeviceInfo(register ClientPtr client)
pad_to_int32(rep.devPrivateSize));
}
- WriteToClient(client, sizeof(xXF86DRIGetDeviceInfoReply), (char *) &rep);
+ WriteToClient(client, sizeof(xXF86DRIGetDeviceInfoReply), &rep);
if (rep.length) {
- WriteToClient(client, rep.devPrivateSize, (char *) pDevPrivate);
+ WriteToClient(client, rep.devPrivateSize, pDevPrivate);
}
return Success;
}
diff --git a/hw/xquartz/applewm.c b/hw/xquartz/applewm.c
index 81db13ea9..d41a81db3 100644
--- a/hw/xquartz/applewm.c
+++ b/hw/xquartz/applewm.c
@@ -157,7 +157,7 @@ ProcAppleWMQueryVersion(register ClientPtr client)
swaps(&rep.sequenceNumber);
swapl(&rep.length);
}
- WriteToClient(client, sizeof(xAppleWMQueryVersionReply), (char *)&rep);
+ WriteToClient(client, sizeof(xAppleWMQueryVersionReply),&rep);
return Success;
}
@@ -533,7 +533,7 @@ ProcAppleWMFrameGetRect(register ClientPtr client)
rep.w = rr.x2 - rr.x1;
rep.h = rr.y2 - rr.y1;
- WriteToClient(client, sizeof(xAppleWMFrameGetRectReply), (char *)&rep);
+ WriteToClient(client, sizeof(xAppleWMFrameGetRectReply),&rep);
return Success;
}
@@ -560,7 +560,7 @@ ProcAppleWMFrameHitTest(register ClientPtr client)
rep.ret = ret;
- WriteToClient(client, sizeof(xAppleWMFrameHitTestReply), (char *)&rep);
+ WriteToClient(client, sizeof(xAppleWMFrameHitTestReply),&rep);
return Success;
}
diff --git a/hw/xquartz/pseudoramiX.c b/hw/xquartz/pseudoramiX.c
index 8bb7f2d01..c14668775 100644
--- a/hw/xquartz/pseudoramiX.c
+++ b/hw/xquartz/pseudoramiX.c
@@ -216,7 +216,7 @@ ProcPseudoramiXGetState(ClientPtr client)
swapl(&rep.length);
swaps(&rep.state);
}
- WriteToClient(client, sizeof(xPanoramiXGetStateReply), (char *)&rep);
+ WriteToClient(client, sizeof(xPanoramiXGetStateReply),&rep);
return Success;
}
@@ -245,7 +245,7 @@ ProcPseudoramiXGetScreenCount(ClientPtr client)
swapl(&rep.length);
swaps(&rep.ScreenCount);
}
- WriteToClient(client, sizeof(xPanoramiXGetScreenCountReply), (char *)&rep);
+ WriteToClient(client, sizeof(xPanoramiXGetScreenCountReply),&rep);
return Success;
}
@@ -279,7 +279,7 @@ ProcPseudoramiXGetScreenSize(ClientPtr client)
swaps(&rep.width);
swaps(&rep.height);
}
- WriteToClient(client, sizeof(xPanoramiXGetScreenSizeReply), (char *)&rep);
+ WriteToClient(client, sizeof(xPanoramiXGetScreenSizeReply),&rep);
return Success;
}
@@ -303,7 +303,7 @@ ProcPseudoramiXIsActive(ClientPtr client)
swapl(&rep.length);
swapl(&rep.state);
}
- WriteToClient(client, sizeof(xXineramaIsActiveReply), (char *)&rep);
+ WriteToClient(client, sizeof(xXineramaIsActiveReply),&rep);
return Success;
}
@@ -329,7 +329,7 @@ ProcPseudoramiXQueryScreens(ClientPtr client)
swapl(&rep.length);
swapl(&rep.number);
}
- WriteToClient(client, sizeof(xXineramaQueryScreensReply), (char *)&rep);
+ WriteToClient(client, sizeof(xXineramaQueryScreensReply),&rep);
if (!noPseudoramiXExtension) {
xXineramaScreenInfo scratch;
@@ -347,7 +347,7 @@ ProcPseudoramiXQueryScreens(ClientPtr client)
swaps(&scratch.width);
swaps(&scratch.height);
}
- WriteToClient(client, sz_XineramaScreenInfo, (char *)&scratch);
+ WriteToClient(client, sz_XineramaScreenInfo,&scratch);
}
}
diff --git a/hw/xquartz/xpr/appledri.c b/hw/xquartz/xpr/appledri.c
index 1bb837958..f77848f13 100644
--- a/hw/xquartz/xpr/appledri.c
+++ b/hw/xquartz/xpr/appledri.c
@@ -105,7 +105,7 @@ ProcAppleDRIQueryVersion(register ClientPtr client)
swaps(&rep.minorVersion);
swapl(&rep.patchVersion);
}
- WriteToClient(client, sizeof(xAppleDRIQueryVersionReply), (char *)&rep);
+ WriteToClient(client, sizeof(xAppleDRIQueryVersionReply), &rep);
return Success;
}
@@ -139,7 +139,7 @@ ProcAppleDRIQueryDirectRenderingCapable(register ClientPtr client)
WriteToClient(client,
sizeof(xAppleDRIQueryDirectRenderingCapableReply),
- (char *)&rep);
+ &rep);
return Success;
}
@@ -168,7 +168,7 @@ ProcAppleDRIAuthConnection(register ClientPtr client)
swapl(&rep.authenticated); /* Yes, this is a CARD32 ... sigh */
}
- WriteToClient(client, sizeof(xAppleDRIAuthConnectionReply), (char *)&rep);
+ WriteToClient(client, sizeof(xAppleDRIAuthConnectionReply), &rep);
return Success;
}
@@ -232,7 +232,7 @@ ProcAppleDRICreateSurface(ClientPtr client)
swapl(&rep.uid);
}
- WriteToClient(client, sizeof(xAppleDRICreateSurfaceReply), (char *)&rep);
+ WriteToClient(client, sizeof(xAppleDRICreateSurfaceReply), &rep);
return Success;
}
diff --git a/hw/xwin/winwindowswm.c b/hw/xwin/winwindowswm.c
index f67c383f3..77c997ae2 100644
--- a/hw/xwin/winwindowswm.c
+++ b/hw/xwin/winwindowswm.c
@@ -95,7 +95,7 @@ ProcWindowsWMQueryVersion(ClientPtr client)
swaps(&rep.sequenceNumber);
swapl(&rep.length);
}
- WriteToClient(client, sizeof(xWindowsWMQueryVersionReply), (char *) &rep);
+ WriteToClient(client, sizeof(xWindowsWMQueryVersionReply), &rep);
return Success;
}
@@ -366,7 +366,7 @@ ProcWindowsWMFrameGetRect(ClientPtr client)
rep.x, rep.y, rep.w, rep.h);
#endif
- WriteToClient(client, sizeof(xWindowsWMFrameGetRectReply), (char *) &rep);
+ WriteToClient(client, sizeof(xWindowsWMFrameGetRectReply), &rep);
return Success;
}