xserver: Branch 'master'
Peter Hutterer
whot at kemper.freedesktop.org
Sun Sep 21 16:09:42 PDT 2008
xkb/xkb.c | 17 +++++------------
1 file changed, 5 insertions(+), 12 deletions(-)
New commits:
commit 8c46505d7d91e0644b19cccc4b342fceb6f86cab
Author: Kim Woelders <kim at woelders.dk>
Date: Mon Sep 22 08:37:29 2008 +0930
xkb: fix use of uninitialized variable.
And some cosmetic changes to use stuff->change consistently.
Signed-off-by: Peter Hutterer <peter.hutterer at redhat.com>
diff --git a/xkb/xkb.c b/xkb/xkb.c
index 754641b..b4a8ed3 100644
--- a/xkb/xkb.c
+++ b/xkb/xkb.c
@@ -6423,13 +6423,10 @@ static int
_XkbSetDeviceInfo(ClientPtr client, DeviceIntPtr dev,
xkbSetDeviceInfoReq *stuff)
{
- unsigned change;
char *wire;
- change = stuff->change;
-
wire= (char *)&stuff[1];
- if (change&XkbXI_ButtonActionsMask) {
+ if (stuff->change&XkbXI_ButtonActionsMask) {
if (!dev->button) {
client->errorValue = _XkbErrCode2(XkbErr_BadClass,ButtonClass);
return XkbKeyboardErrorCode;
@@ -6458,14 +6455,13 @@ static int
_XkbSetDeviceInfoCheck(ClientPtr client, DeviceIntPtr dev,
xkbSetDeviceInfoReq *stuff)
{
- unsigned change;
char *wire;
xkbExtensionDeviceNotify ed;
bzero((char *)&ed,SIZEOF(xkbExtensionDeviceNotify));
ed.deviceID= dev->id;
wire= (char *)&stuff[1];
- if (change&XkbXI_ButtonActionsMask) {
+ if (stuff->change&XkbXI_ButtonActionsMask) {
int nBtns,sz,i;
XkbAction * acts;
DeviceIntPtr kbd;
@@ -6495,8 +6491,8 @@ _XkbSetDeviceInfoCheck(ClientPtr client, DeviceIntPtr dev,
}
if (stuff->change&XkbXI_IndicatorsMask) {
int status= Success;
- wire= SetDeviceIndicators(wire,dev,change,stuff->nDeviceLedFBs,
- &status,client,&ed);
+ wire= SetDeviceIndicators(wire,dev,stuff->change,
+ stuff->nDeviceLedFBs, &status,client,&ed);
if (status!=Success)
return status;
}
@@ -6508,7 +6504,6 @@ _XkbSetDeviceInfoCheck(ClientPtr client, DeviceIntPtr dev,
int
ProcXkbSetDeviceInfo(ClientPtr client)
{
- unsigned int change;
DeviceIntPtr dev;
int rc;
@@ -6518,10 +6513,8 @@ ProcXkbSetDeviceInfo(ClientPtr client)
if (!(client->xkbClientFlags&_XkbClientInitialized))
return BadAccess;
- change = stuff->change;
-
CHK_ANY_DEVICE(dev, stuff->deviceSpec, client, DixManageAccess);
- CHK_MASK_LEGAL(0x01,change,XkbXI_AllFeaturesMask);
+ CHK_MASK_LEGAL(0x01,stuff->change,XkbXI_AllFeaturesMask);
rc = _XkbSetDeviceInfoCheck(client, dev, stuff);
More information about the xorg-commit
mailing list