Deliver correct event when releasing keys on VT switch.
In commit41bb9fce47
, the event delivery loop for Xinput enabled keyboards was changed and accidentally used the wrong index variable, causing random events to be delivered when returning from VT switch. In addition, in commitaeba855b07
, SIGIO was blocked during delivery of these events, but not for the entire period the xf86Events array was being used. Block SIGIO for the whole loop to avoid other event delivery from trashing the key release events.
This commit is contained in:
parent
643a263f2c
commit
aa7ed1f5f3
|
@ -811,9 +811,11 @@ xf86ReleaseKeys(DeviceIntPtr pDev)
|
|||
(*pDev->public.processInputProc) (&ke, pDev, 1);
|
||||
}
|
||||
else {
|
||||
int sigstate = xf86BlockSIGIO ();
|
||||
nevents = GetKeyboardEvents(xf86Events, pDev, KeyRelease, i);
|
||||
for (j = 0; j < nevents; j++)
|
||||
EqEnqueue(pDev, xf86Events + i);
|
||||
mieqEnqueue(pDev, xf86Events + j);
|
||||
xf86UnblockSIGIO(sigstate);
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user