diff options
Diffstat (limited to 'src/evdev.c')
-rw-r--r-- | src/evdev.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/evdev.c b/src/evdev.c index ba2a98c..456c7aa 100644 --- a/src/evdev.c +++ b/src/evdev.c @@ -1157,7 +1157,7 @@ EvdevKbdCtrl(DeviceIntPtr device, KeybdCtrl *ctrl) }; InputInfoPtr pInfo; - struct input_event ev[ArrayLength(bits)]; + struct input_event ev[ArrayLength(bits) + 1]; int i; memset(ev, 0, sizeof(ev)); @@ -1169,6 +1169,10 @@ EvdevKbdCtrl(DeviceIntPtr device, KeybdCtrl *ctrl) ev[i].value = (ctrl->leds & bits[i].xbit) > 0; } + ev[i].type = EV_SYN; + ev[i].code = SYN_REPORT; + ev[i].value = 0; + write(pInfo->fd, ev, sizeof ev); } |