glx: use sizeof() for reply struct

The reply struct's size can safely be determined by the sizeof()
operator, so no need for using an extra define here. Making the code
easier to read and also open the door for future convenience macros
that might determine the buffer size on their own.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1665>
This commit is contained in:
Enrico Weigelt, metux IT consult
2024-08-28 13:27:23 +02:00
committed by Marge Bot
parent 558ded4dbf
commit 6bd673ab15
8 changed files with 26 additions and 26 deletions

View File

@@ -198,7 +198,7 @@ __glXDisp_RenderMode(__GLXclientState * cl, GLbyte * pc)
.size = nitems,
.newMode = newMode
};
WriteToClient(client, sz_xGLXRenderModeReply, &reply);
WriteToClient(client, sizeof(xGLXRenderModeReply), &reply);
if (retBytes) {
WriteToClient(client, retBytes, retBuffer);
}