eloop: prevent recursive dispatching

We do not support recursive dispatching so prevent it explicitely.

Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
This commit is contained in:
David Herrmann 2012-07-21 20:20:09 +02:00
parent f3609f6ed9
commit 1715ec526a

View File

@ -592,6 +592,10 @@ int ev_eloop_dispatch(struct ev_eloop *loop, int timeout)
return -EINVAL;
if (loop->exit)
return llog_EINVAL(loop);
if (loop->dispatching) {
llog_warn(loop, "recursive dispatching not allowed");
return -EOPNOTSUPP;
}
count = epoll_wait(loop->efd,
loop->cur_fds,