dri: use REPLY_*() macros for preparing / sending replies

Use the new macros for preparing and sending replies to clients.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
This commit is contained in:
Enrico Weigelt, metux IT consult
2024-07-18 19:01:52 +02:00
parent b258451ab9
commit 0fd1c0dc4c

View File

@@ -81,11 +81,10 @@ ProcXF86DRIQueryVersion(register ClientPtr client)
.patchVersion = SERVER_XF86DRI_PATCH_VERSION
};
if (client->swapped) {
swaps(&reply.majorVersion);
swaps(&reply.minorVersion);
swapl(&reply.patchVersion);
}
REPLY_FIELD_CARD16(majorVersion);
REPLY_FIELD_CARD16(minorVersion);
REPLY_FIELD_CARD32(patchVersion);
return X_SEND_REPLY_SIMPLE(client, reply);
}
@@ -112,7 +111,7 @@ ProcXF86DRIQueryDirectRenderingCapable(register ClientPtr client)
if (!client->local || client->swapped)
isCapable = 0;
xXF86DRIQueryDirectRenderingCapableReply reply = {
xXF86DRIQueryDirectRenderingCapableReply rep = {
.isCapable = isCapable
};
@@ -411,7 +410,7 @@ ProcXF86DRIGetDeviceInfo(register ClientPtr client)
X_REQUEST_HEAD_STRUCT(xXF86DRIGetDeviceInfoReq);
drm_handle_t hFrameBuffer;
void *pDevPrivate;
void *pDevPrivate = NULL;
ScreenPtr pScreen = dixGetScreenPtr(stuff->screen);
if (!pScreen) {