xkb: inline SProcXkbListComponents()

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 16:40:47 +02:00
committed by Enrico Weigelt
parent 25adcbfd5a
commit 9eba2365c9
2 changed files with 9 additions and 14 deletions

View File

@@ -5514,15 +5514,20 @@ GetComponentSpec(ClientPtr client, xkbGetKbdByNameReq *stuff,
int
ProcXkbListComponents(ClientPtr client)
{
REQUEST(xkbListComponentsReq);
REQUEST_AT_LEAST_SIZE(xkbListComponentsReq);
if (client->swapped) {
swaps(&stuff->deviceSpec);
swaps(&stuff->maxNames);
}
DeviceIntPtr dev;
unsigned len;
unsigned char *str;
uint8_t size;
int i;
REQUEST(xkbListComponentsReq);
REQUEST_AT_LEAST_SIZE(xkbListComponentsReq);
if (!(client->xkbClientFlags & _XkbClientInitialized))
return BadAccess;

View File

@@ -352,16 +352,6 @@ SProcXkbPerClientFlags(ClientPtr client)
return ProcXkbPerClientFlags(client);
}
static int _X_COLD
SProcXkbListComponents(ClientPtr client)
{
REQUEST(xkbListComponentsReq);
REQUEST_AT_LEAST_SIZE(xkbListComponentsReq);
swaps(&stuff->deviceSpec);
swaps(&stuff->maxNames);
return ProcXkbListComponents(client);
}
static int _X_COLD
SProcXkbGetKbdByName(ClientPtr client)
{
@@ -457,7 +447,7 @@ SProcXkbDispatch(ClientPtr client)
case X_kbPerClientFlags:
return SProcXkbPerClientFlags(client);
case X_kbListComponents:
return SProcXkbListComponents(client);
return ProcXkbListComponents(client);
case X_kbGetKbdByName:
return SProcXkbGetKbdByName(client);
case X_kbGetDeviceInfo: