I was porting some code from select () to kqueue () today, and I noticed that kevent () did not seem to have an analogue for the select () function "exception-set".
That is, function () function-signature:
int select(int nfds, fd_set *restrict readfds, fd_set *restrict writefds, fd_set *restrict errorfds, struct timeval *restrict timeout);
... and with kevent (), EVFILT_READ matches (readfds), and EVFILT_WRITE matches (writefds), but I don't see anything like EVFILT_ERROR that matches (errorfds).
Is there really no support for socket error conditions in kevent (), or is it there, but implemented in some way, which is not obvious to me?
source share