glx: replace __GLX_SWAP_INT() by swapl()

We have an optimized function for this, so use it.
This commit is contained in:
Enrico Weigelt, metux IT consult
2025-09-02 16:08:11 +02:00
committed by Enrico Weigelt
parent d438dfc677
commit c339338277
8 changed files with 199 additions and 311 deletions

View File

@@ -328,7 +328,6 @@ DoGetString(__GLXclientState * cl, GLbyte * pc, GLboolean need_swap)
GLenum name;
const char *string;
__GLX_DECLARE_SWAP_VARIABLES;
int error;
char *buf = NULL, *buf1 = NULL;
GLint length = 0;
@@ -339,8 +338,8 @@ DoGetString(__GLXclientState * cl, GLbyte * pc, GLboolean need_swap)
* the name.
*/
if (need_swap) {
__GLX_SWAP_INT(pc + 4);
__GLX_SWAP_INT(pc + __GLX_SINGLE_HDR_SIZE);
swapl((CARD32*)(pc + 4));
swapl((CARD32*)(pc + __GLX_SINGLE_HDR_SIZE));
}
cx = __glXForceCurrent(cl, __GLX_GET_SINGLE_CONTEXT_TAG(pc), &error);