On Thu, Apr 8, 2010 at 7:46 AM, Sherif Fanous <
sherif.fanous@xxxxxxxxx> wrote:
> Hi
> I am using libevent 2.0.4 alpha in my C application.
> The below snapshot of my code occasionally encounters the following 2
> problems
>
> [err] event.c:1961: Assertion !(ev->ev_flags & ~EVLIST_ALL) failed in
> event_del_internal
> Aborted
> Segmentation Fault. I've traced down that it occurs in the event_base_loop
> call
>
> In a nutshell, I have a linked list of servers. I loop through every server,
> if I'm connected to that server then I create an event for the socket. I
> then run the event loop with a timeout. I use the timeout to break out of
> the event loop and check if the termination condition has been encountered
> in another thread. I also run the event loop with EVLOOP_ONCE to break out
> of the loop as soon as 1 event triggers to re-evaluate the linked list of
> servers (new connections established, current connections terminated, ...)
> When I break of the event loop, I delete the events and free them.
> Can anyone please tell me what I'm doing wrong here? Is it an internal
> libevent problem, or is my code messing up somewhere?
Try running 2.0.5-beta with the debugging options. (That is, call