mirror of
https://github.com/X11Libre/xf86-input-libinput.git
synced 2026-03-24 01:24:04 +00:00
Don't process events from devices that got removed already
If the driver doesn't have a pInfo reference anymore for a libinput device, don't bother processing events, the device was already removed. This was triggered by the libevdev test suite which adds/removes devices very quickly. Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
This commit is contained in:
@@ -610,7 +610,7 @@ xf86libinput_handle_event(struct libinput_event *event)
|
||||
device = libinput_event_get_device(event);
|
||||
pInfo = libinput_device_get_user_data(device);
|
||||
|
||||
if (pInfo && !pInfo->dev->public.on)
|
||||
if (!pInfo || !pInfo->dev->public.on)
|
||||
return;
|
||||
|
||||
switch (libinput_event_get_type(event)) {
|
||||
|
||||
Reference in New Issue
Block a user