xkb: inline SProcXkbSetGeometry()

No need to have whole extra functions for just a few LoC.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
This commit is contained in:
Enrico Weigelt, metux IT consult
2025-09-24 14:38:27 +02:00
committed by Enrico Weigelt
parent 4ae70b0a09
commit 25adcbfd5a
2 changed files with 15 additions and 20 deletions

View File

@@ -5324,12 +5324,23 @@ _XkbSetGeometry(ClientPtr client, DeviceIntPtr dev, xkbSetGeometryReq * stuff)
int
ProcXkbSetGeometry(ClientPtr client)
{
DeviceIntPtr dev;
int rc;
REQUEST(xkbSetGeometryReq);
REQUEST_AT_LEAST_SIZE(xkbSetGeometryReq);
if (client->swapped) {
swaps(&stuff->deviceSpec);
swapl(&stuff->name);
swaps(&stuff->widthMM);
swaps(&stuff->heightMM);
swaps(&stuff->nProperties);
swaps(&stuff->nColors);
swaps(&stuff->nDoodads);
swaps(&stuff->nKeyAliases);
}
DeviceIntPtr dev;
int rc;
if (!(client->xkbClientFlags & _XkbClientInitialized))
return BadAccess;

View File

@@ -338,22 +338,6 @@ SProcXkbGetGeometry(ClientPtr client)
return ProcXkbGetGeometry(client);
}
static int _X_COLD
SProcXkbSetGeometry(ClientPtr client)
{
REQUEST(xkbSetGeometryReq);
REQUEST_AT_LEAST_SIZE(xkbSetGeometryReq);
swaps(&stuff->deviceSpec);
swapl(&stuff->name);
swaps(&stuff->widthMM);
swaps(&stuff->heightMM);
swaps(&stuff->nProperties);
swaps(&stuff->nColors);
swaps(&stuff->nDoodads);
swaps(&stuff->nKeyAliases);
return ProcXkbSetGeometry(client);
}
static int _X_COLD
SProcXkbPerClientFlags(ClientPtr client)
{
@@ -469,7 +453,7 @@ SProcXkbDispatch(ClientPtr client)
case X_kbGetGeometry:
return SProcXkbGetGeometry(client);
case X_kbSetGeometry:
return SProcXkbSetGeometry(client);
return ProcXkbSetGeometry(client);
case X_kbPerClientFlags:
return SProcXkbPerClientFlags(client);
case X_kbListComponents: