Warn about a SYN_DROPPED right after finishing a sync
authorPeter Hutterer <peter.hutterer@who-t.net>
Fri, 17 Jan 2014 00:15:33 +0000 (10:15 +1000)
committerPeter Hutterer <peter.hutterer@who-t.net>
Tue, 21 Jan 2014 23:15:14 +0000 (09:15 +1000)
commit642c91fc6a5e55cead3bd85bbc599792fcd6df50
tree85f81c223fc7005029c45d75b13a8270070b163d
parent0c0188698554a00eb0d910ef7610998156724f49
Warn about a SYN_DROPPED right after finishing a sync

If the first event after a completed device sync is a SYN_DROPPED, warn the
user that they're not fast enough handling this device.

The test for this is rather complicated since we can't write SYN_DROPPED
through uinput so we have to juggle the device fd and a pipe and switch
between the two at the right time (taking into account that libevdev will read
events from the fd whenever it can).

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
libevdev/libevdev.c
test/test-libevdev-events.c