XI: directly write out X_GetDeviceDontPropagateList reply
Write out X_GetDeviceDontPropagateList the reply directly (and do the swapping within the request handler) instead of going through separate callback that's having demux the replies again. Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
This commit is contained in:
parent
c1d828910a
commit
d082992690
|
@ -421,11 +421,7 @@ SReplyIDispatch(ClientPtr client, int len, xGrabDeviceReply * rep)
|
|||
{
|
||||
/* All we look at is the type field */
|
||||
/* This is common to all replies */
|
||||
if (rep->RepType == X_GetDeviceDontPropagateList)
|
||||
SRepXGetDeviceDontPropagateList(client, len,
|
||||
(xGetDeviceDontPropagateListReply *)
|
||||
rep);
|
||||
else if (rep->RepType == X_GetDeviceMotionEvents)
|
||||
if (rep->RepType == X_GetDeviceMotionEvents)
|
||||
SRepXGetDeviceMotionEvents(client, len,
|
||||
(xGetDeviceMotionEventsReply *) rep);
|
||||
else if (rep->RepType == X_GrabDevice)
|
||||
|
|
24
Xi/getprop.c
24
Xi/getprop.c
|
@ -126,7 +126,12 @@ ProcXGetDeviceDontPropagateList(ClientPtr client)
|
|||
}
|
||||
}
|
||||
|
||||
WriteReplyToClient(client, sizeof(xGetDeviceDontPropagateListReply), &rep);
|
||||
if (client->swapped) {
|
||||
swaps(&rep.sequenceNumber);
|
||||
swapl(&rep.length);
|
||||
swaps(&rep.count);
|
||||
}
|
||||
WriteToClient(client, sizeof(xGetDeviceDontPropagateListReply), &rep);
|
||||
|
||||
if (count) {
|
||||
client->pSwapReplyFunc = (ReplySwapPtr) Swap32Write;
|
||||
|
@ -163,20 +168,3 @@ XEventClass
|
|||
}
|
||||
return buf;
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
*
|
||||
* This procedure writes the reply for the XGetDeviceDontPropagateList function,
|
||||
* if the client and server have a different byte ordering.
|
||||
*
|
||||
*/
|
||||
|
||||
void _X_COLD
|
||||
SRepXGetDeviceDontPropagateList(ClientPtr client, int size,
|
||||
xGetDeviceDontPropagateListReply * rep)
|
||||
{
|
||||
swaps(&rep->sequenceNumber);
|
||||
swapl(&rep->length);
|
||||
swaps(&rep->count);
|
||||
WriteToClient(client, size, rep);
|
||||
}
|
||||
|
|
|
@ -43,9 +43,4 @@ XEventClass *ClassFromMask(XEventClass * /* buf */ ,
|
|||
int /* mode */
|
||||
);
|
||||
|
||||
void SRepXGetDeviceDontPropagateList(ClientPtr /* client */ ,
|
||||
int /* size */ ,
|
||||
xGetDeviceDontPropagateListReply * /* rep */
|
||||
);
|
||||
|
||||
#endif /* GETPROP_H */
|
||||
|
|
Loading…
Reference in New Issue