diff options
Diffstat (limited to 'minui/events.c')
-rw-r--r-- | minui/events.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/minui/events.c b/minui/events.c index df7dad448..9e4255dd7 100644 --- a/minui/events.c +++ b/minui/events.c @@ -16,6 +16,8 @@ #include <stdio.h> #include <stdlib.h> +#include <string.h> +#include <unistd.h> #include <fcntl.h> #include <dirent.h> #include <sys/epoll.h> @@ -78,8 +80,8 @@ int ev_init(ev_callback input_cb, void *data) } /* TODO: add ability to specify event masks. For now, just assume - * that only EV_KEY and EV_REL event types are ever needed. */ - if (!test_bit(EV_KEY, ev_bits) && !test_bit(EV_REL, ev_bits)) { + * that only EV_KEY, EV_REL & EV_SW event types are ever needed. */ + if (!test_bit(EV_KEY, ev_bits) && !test_bit(EV_REL, ev_bits) && !test_bit(EV_SW, ev_bits)) { close(fd); continue; } |