mirror of
https://github.com/X11Libre/xserver.git
synced 2026-01-26 14:03:17 +00:00
Xext: geext: use REQUEST_HEAD_STRUCT and REQUEST_FIELD_* macros
Use the new macros to make request struct parsing / field swapping much easier. Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
This commit is contained in:
parent
2e6a9a1fbc
commit
6f7aa46c51
12
Xext/geext.c
12
Xext/geext.c
@ -67,16 +67,12 @@ static void SGEGenericEvent(xEvent *from, xEvent *to);
|
||||
static int
|
||||
ProcGEQueryVersion(ClientPtr client)
|
||||
{
|
||||
X_REQUEST_HEAD_STRUCT(xGEQueryVersionReq);
|
||||
X_REQUEST_FIELD_CARD16(majorVersion);
|
||||
X_REQUEST_FIELD_CARD16(minorVersion);
|
||||
|
||||
GEClientInfoPtr pGEClient = GEGetClient(client);
|
||||
|
||||
REQUEST(xGEQueryVersionReq);
|
||||
REQUEST_SIZE_MATCH(xGEQueryVersionReq);
|
||||
|
||||
if (client->swapped) {
|
||||
swaps(&stuff->majorVersion);
|
||||
swaps(&stuff->minorVersion);
|
||||
}
|
||||
|
||||
xGEQueryVersionReply reply = {
|
||||
.RepType = X_GEQueryVersion,
|
||||
/* return the supported version by the server */
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user