interactive-evdev: fix missing initialization

Accidentally got lost in 6b65be4.

Signed-off-by: Ran Benita <ran@unusedvar.com>
master
Ran Benita 2021-03-28 16:10:52 +03:00
parent 6b65be4c4e
commit c14910a0de
1 changed files with 1 additions and 1 deletions

View File

@ -313,10 +313,10 @@ read_keyboard(struct keyboard *kbd)
static int
loop(struct keyboard *kbds)
{
int ret = -1;
struct keyboard *kbd;
nfds_t nfds, i;
struct pollfd *fds = NULL;
int ret;
for (kbd = kbds, nfds = 0; kbd; kbd = kbd->next, nfds++) {}
fds = calloc(nfds, sizeof(*fds));