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

[Libevent-users] error handling



I'm a new libevent user.  I have some pretty old code with select() at the
heart of its mainloop.  We're running issues with the number of fd's in an
fd_set on some platform.  I decided to use libevent since it abstracts
away using the whatever methods are available on different platforms.

How do we do error handling in the dispatch family of functions?  For
example, lets say that event_loop() returns -1 and errno is EBADF?  How do
I figure out which fd is bad?  Can I get a list of all the registered
events?

The old code did a brute force method by iterating through the fd_sets and
then issuing an individual select for each fd to see if it failed with
EBADF.

-- 
Kathryn
http://womensfooty.com
National Team Donation - http://womensfooty.com/freedom/donate
***********************************************************************
To unsubscribe, send an e-mail to majordomo@xxxxxxxxxxxxx with
unsubscribe libevent-users    in the body.