On Fri, Sep 18, 2009 at 11:09:52AM +0800, Adrian Chadd wrote:
> On Thu, Sep 17, 2009, Nick Mathewson wrote:
>
> > > Nick, is this actually documented anywhere?
> >
> > Not that I recall, and it really ought to be. Anybody want to write the
> > documentation patch?
>
> I've been threatening to
On Thu, Sep 17, 2009 at 07:51:58PM -0700, Gilad Benjamini wrote:
> I just resolved a similar issue today, where I needed to close a file
> descriptor AFTER deleting an event.
>
> My symptoms, though, were different.
>
> What underlying mechanism is your libevent using ?
>
> In my case it is epol
I forgot to mention that I am using libevent-2.02alpha.
I think it definately makes sence to free the event before closing the
handle, but it just didn't occur to me before.
On Fri, Sep 18, 2009 at 10:57 AM, Adrian Chadd wrote:
> Well, the order of which you can do this depends on what the under
On Thu, Sep 17, 2009, Nick Mathewson wrote:
> > Nick, is this actually documented anywhere?
>
> Not that I recall, and it really ought to be. Anybody want to write the
> documentation patch?
I've been threatening to do this for ages. I may as well start now.
Is there a project wiki or somethi
On Fri, Sep 18, 2009 at 10:57:25AM +0800, Adrian Chadd wrote:
> Well, the order of which you can do this depends on what the underlying OS
> will
> "do for you".
>
> I'd suggest sticking to "delete event, close socket" usage. Anything else
> isn't portable.
>
> Nick, is this actually documented
Well, the order of which you can do this depends on what the underlying OS will
"do for you".
I'd suggest sticking to "delete event, close socket" usage. Anything else
isn't portable.
Nick, is this actually documented anywhere?
Adrian
On Thu, Sep 17, 2009, Gilad Benjamini wrote:
> I just reso
I just resolved a similar issue today, where I needed to close a file
descriptor AFTER deleting an event.
My symptoms, though, were different.
What underlying mechanism is your libevent using ?
In my case it is epoll. With select or poll my scenario had no problems, in
spite of the wrong order.
On Thu, Sep 17, 2009 at 02:56:59PM +0200, nicolas dumont wrote:
> Hi,
>
> I'm using events in 1.4.12-stable.
[...]
> Finnaly, to prevent to go in the infinite loop ,
> do I have to run event_del(&ev) each time before using event_set(&ev) ?
This is exactly so. You can't call event_set or event_
Hi,
I'm using events in 1.4.12-stable.
Sometimes, my daemon, which uses event_base_loop()
goes in an infinite loop ( verbose traces below ).
This infinite loop is inside function event_process_active() which
calls event_del() with ev_flags=0x80 ( =EVLIST_INIT)
This flags is not managed by event