Re: [Libevent-users] Equivalent of event_self_cbarg() in libevent-2.0?

2012-09-18 Thread Nir Soffer
On Sep 18, 2012, at 2:28 PM, Chirag Kantharia wrote: Hi, I had a signal handler which used libevent-1.4.x, and which looked like this: int main (void) { ... struct event sigev; memset(&sigev, 0, sizeof(sigev)); event_set(&sigev, SIGINT, EV_SIGNAL|EV_PERSIST, sig_handler, &sigev); ... ev

Re: [Libevent-users] pthread_cond_timedwait realtime clock race

2012-09-18 Thread Nick Mathewson
On Tue, Sep 18, 2012 at 4:14 PM, David Goulet wrote: > -BEGIN PGP SIGNED MESSAGE- > Hash: SHA512 > > Hi everyone, > > I'm David from the LTTng project (http://lttng.org). I'm sharing here > an issue we ran into. The solution could benefit the libevent project. Hi, and thanks for the heads

[Libevent-users] pthread_cond_timedwait realtime clock race

2012-09-18 Thread David Goulet
-BEGIN PGP SIGNED MESSAGE- Hash: SHA512 Hi everyone, I'm David from the LTTng project (http://lttng.org). I'm sharing here an issue we ran into. The solution could benefit the libevent project. A couple days ago we've hit a clock race using pthread timedwait conditions (although document

Re: [Libevent-users] Equivalent of event_self_cbarg() in libevent-2.0?

2012-09-18 Thread Ross Lagerwall
On 09/18/2012 01:28 PM, Chirag Kantharia wrote: > Hi, > > I had a signal handler which used libevent-1.4.x, and which looked > like this: > > int main (void) { > ... > struct event sigev; > memset(&sigev, 0, sizeof(sigev)); > event_set(&sigev, SIGINT, EV_SIGNAL|EV_PERSIST, sig_handler, &s

[Libevent-users] Equivalent of event_self_cbarg() in libevent-2.0?

2012-09-18 Thread Chirag Kantharia
Hi, I had a signal handler which used libevent-1.4.x, and which looked like this: int main (void) { ... struct event sigev; memset(&sigev, 0, sizeof(sigev)); event_set(&sigev, SIGINT, EV_SIGNAL|EV_PERSIST, sig_handler, &sigev); ... event_dispatch(); return 0; } The sig_handler look