Commit a425abf0 authored by Peter Hutterer's avatar Peter Hutterer

xkb: don't attempt to filter events for devices without key classes.

Reported by Magnus Kessler.
Signed-off-by: default avatarPeter Hutterer <peter.hutterer@redhat.com>
parent a85f0d6b
......@@ -819,7 +819,8 @@ XkbSrvInfoPtr xkbi;
pXDev = inputInfo.keyboard;
}
xkbi= pXDev->key->xkbInfo;
xkbi= (pXDev->key) ? pXDev->key->xkbInfo : NULL;
if ( pClient->xkbClientFlags & _XkbClientInitialized ) {
if ((xkbDebugFlags&0x10)&&
((xE[0].u.u.type==KeyPress)||(xE[0].u.u.type==KeyRelease)||
......@@ -841,6 +842,10 @@ XkbSrvInfoPtr xkbi;
(_XkbIsReleaseEvent(xE[0].u.u.type)) ) {
return False;
}
if (!xkbi)
return True;
if ((pXDev->deviceGrab.grab != NullGrab)
&& pXDev->deviceGrab.fromPassiveGrab &&
((xE[0].u.u.type==KeyPress)||(xE[0].u.u.type==KeyRelease)||
......@@ -884,6 +889,9 @@ XkbSrvInfoPtr xkbi;
else {
register CARD8 type;
if (!xkbi)
return True;
for (i=0;i<nEvents;i++) {
type= xE[i].u.u.type;
if ((xkbDebugFlags&0x4)&&
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment