uloop: use a waker for notifying sigchld and loop cancel events
authorYousong Zhou <yszhou4tech@gmail.com>
Thu, 9 Jun 2016 02:20:32 +0000 (10:20 +0800)
committerFelix Fietkau <nbd@nbd.name>
Wed, 15 Jun 2016 09:54:37 +0000 (11:54 +0200)
commit4e3a47a4cb438866bc4b9cb2f5d16226ffb48502
tree1261027a581bd5f24ce2360677e776317c463bca
parent1257a38a6e64511207bb3b077ca7e8e1a3338fc1
uloop: use a waker for notifying sigchld and loop cancel events

Fix a race condition when do_sigchld, uloop_cancelled were set just
before epoll_wait(timeout=-1), resulting the loop stuck in the syscall
without noticing the events just happened

Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
Signed-off-by: Felix Fietkau <nbd@nbd.name>
uloop-epoll.c
uloop-kqueue.c
uloop.c