Xi: check for existence of the button class before accessing it
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
This commit is contained in:
parent
e8094d8f3f
commit
5ae129baef
|
@ -843,6 +843,8 @@ UpdateDeviceState(DeviceIntPtr device, DeviceEvent* event)
|
||||||
for (sd = inputInfo.devices; sd; sd = sd->next) {
|
for (sd = inputInfo.devices; sd; sd = sd->next) {
|
||||||
if (sd->isMaster || sd->u.master != device)
|
if (sd->isMaster || sd->u.master != device)
|
||||||
continue;
|
continue;
|
||||||
|
if (!sd->button)
|
||||||
|
continue;
|
||||||
if ((sd->button->down[key>>3] & bit) != 0)
|
if ((sd->button->down[key>>3] & bit) != 0)
|
||||||
return DONT_PROCESS;
|
return DONT_PROCESS;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue