Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.openwrt.org/project/libubox.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Crispin <blogic@openwrt.org>2015-03-21 07:49:38 +0300
committerJohn Crispin <blogic@openwrt.org>2015-03-21 07:50:23 +0300
commitb8d9b382e39823850331edc2a92379173daf1be3 (patch)
tree36f75052403f0a6ac44cd0b4aff228b246677ef7 /uloop.c
parent2a9edb464215d17c61fdaa6fbd97c99f1f130812 (diff)
allow process callback to call uloop_end()
Signed-off-by: John Crispin <blogic@openwrt.org>
Diffstat (limited to 'uloop.c')
-rw-r--r--uloop.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/uloop.c b/uloop.c
index 9ebeca6..ea160a0 100644
--- a/uloop.c
+++ b/uloop.c
@@ -680,11 +680,13 @@ void uloop_run(void)
{
uloop_gettime(&tv);
uloop_process_timeouts(&tv);
- if (uloop_cancelled)
- break;
if (do_sigchld)
uloop_handle_processes();
+
+ if (uloop_cancelled)
+ break;
+
uloop_gettime(&tv);
uloop_run_events(uloop_get_next_timeout(&tv));
}