X-Git-Url: https://notaz.gp2x.de/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=common%2Finput.c;h=a6d331e09da02ca233350ec8d6d2375056467777;hb=74065be8cdfbcccb7e12d7e19f0a7cb35538db06;hp=182e9fb26042a1697ea192d8aa4dcbd6292d0985;hpb=e9b2926437ccf6b630cf79e00ed98f7934201c20;p=libpicofe.git diff --git a/common/input.c b/common/input.c index 182e9fb..a6d331e 100644 --- a/common/input.c +++ b/common/input.c @@ -355,9 +355,6 @@ int in_update_keycode(int *dev_id_out, int *is_down_out, int timeout_ms) drv = &DRV(in_devices[dev_id].drv_id); result = drv->update_keycode(in_devices[dev_id].drv_data, &is_down); - - /* update_keycode() might return -1 when some not interesting - * event happened, like sync event for evdev. */ if (result >= 0) break; @@ -370,7 +367,7 @@ int in_update_keycode(int *dev_id_out, int *is_down_out, int timeout_ms) } } - if (result == -1) + if (result < 0) return -1; finish: /* keep track of menu key state, to allow mixing