diff options
author | Felix Fietkau <nbd@nbd.name> | 2017-06-17 12:47:21 +0300 |
---|---|---|
committer | Felix Fietkau <nbd@nbd.name> | 2017-06-17 12:47:49 +0300 |
commit | fd57eea9f37e447814afbf934db626288aac23c4 (patch) | |
tree | 397746ddf7908aad0048bf20f4b746151e430e3d /uloop.c | |
parent | 4bc3decf8743c0add93d434a639bb1b449b6da11 (diff) |
uloop: allow passing 0 as timeout to uloop_run
Useful for processing only immediate timers and fds
Signed-off-by: Felix Fietkau <nbd@nbd.name>
Diffstat (limited to 'uloop.c')
-rw-r--r-- | uloop.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -548,7 +548,7 @@ int uloop_run_timeout(int timeout) uloop_gettime(&tv); next_time = uloop_get_next_timeout(&tv); - if (timeout > 0 && timeout < next_time) + if (timeout >= 0 && timeout < next_time) next_time = timeout; uloop_run_events(next_time); } |