Hi, I've add event_base_set before event_add, now it seems that it works.
On 10/9/07, Quan Sun <[EMAIL PROTECTED]> wrote: > Hi, > > These days I'm working on a web client project. The design is rather > simple, and I use two threads. > > One thread creates sockets, with a given time-varing speed, then these > sockets are passed to second thread. The second thread is a > event_dispatch(), it perform all the actual work. > > My question is, what is the best method to pass events between thread? > I used event_add in first thread, and these two threads share event. > But it seems that libevent is leaking fds in this case, I've read some > of 1.2a's codes, libevent itself does not have thread lock in > event_add. > > -- > > Quan Sun > -- -- 世界很大, 时间很长。 Quan Sun
_______________________________________________ Libevent-users mailing list Libevent-users@monkey.org http://monkey.org/mailman/listinfo/libevent-users