[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [Libevent-users] about exit when using flag EVLOOP_NO_EXIT_ON_EMPTY

On Sat, Jul 7, 2012 at 6:50 AM, debuguo <wateraworld@xxxxxxxxx> wrote:
> Hello, everyone.
> I noticed one new feature added in libevent 2.1, which was the flag of
> event_base_new, EVLOOP_NO_EXIT_ON_EMPTY.
> BUT I don't know how to exit that event_base loop. even the
> event_base_loopexit or event_base_loopbreak seem not work.
> Please tell me if you know the answer.
> Thank you.

Those functions should work; if they don't, it is likely that you
forgot to enable threading before creating your event base.

(Of course, you'll need to call them from another thread: it's not
possible to call them from the event_base's loop thread, since that
thread is busy running no events.)
To unsubscribe, send an e-mail to majordomo@xxxxxxxxxxxxx with
unsubscribe libevent-users    in the body.