xkb: inline SProcXkbGetDeviceInfo()

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:42:46 +02:00
committed by Enrico Weigelt
parent 9eba2365c9
commit 8c545a6528
2 changed files with 11 additions and 16 deletions

View File

@@ -6198,15 +6198,22 @@ FillDeviceLedFBs(DeviceIntPtr dev, int class, int id, unsigned wantLength,
int
ProcXkbGetDeviceInfo(ClientPtr client)
{
REQUEST(xkbGetDeviceInfoReq);
REQUEST_SIZE_MATCH(xkbGetDeviceInfoReq);
if (client->swapped) {
swaps(&stuff->deviceSpec);
swaps(&stuff->wanted);
swaps(&stuff->ledClass);
swaps(&stuff->ledID);
}
DeviceIntPtr dev;
int status;
unsigned length, nameLen;
CARD16 ledClass, ledID;
unsigned wanted;
REQUEST(xkbGetDeviceInfoReq);
REQUEST_SIZE_MATCH(xkbGetDeviceInfoReq);
if (!(client->xkbClientFlags & _XkbClientInitialized))
return BadAccess;

View File

@@ -363,18 +363,6 @@ SProcXkbGetKbdByName(ClientPtr client)
return ProcXkbGetKbdByName(client);
}
static int _X_COLD
SProcXkbGetDeviceInfo(ClientPtr client)
{
REQUEST(xkbGetDeviceInfoReq);
REQUEST_SIZE_MATCH(xkbGetDeviceInfoReq);
swaps(&stuff->deviceSpec);
swaps(&stuff->wanted);
swaps(&stuff->ledClass);
swaps(&stuff->ledID);
return ProcXkbGetDeviceInfo(client);
}
static int _X_COLD
SProcXkbSetDeviceInfo(ClientPtr client)
{
@@ -451,7 +439,7 @@ SProcXkbDispatch(ClientPtr client)
case X_kbGetKbdByName:
return SProcXkbGetKbdByName(client);
case X_kbGetDeviceInfo:
return SProcXkbGetDeviceInfo(client);
return ProcXkbGetDeviceInfo(client);
case X_kbSetDeviceInfo:
return SProcXkbSetDeviceInfo(client);
case X_kbSetDebuggingFlags: