Is there a way to duplicate a file descriptor created using epoll_create, in such a way that the copy can be modified (adding/removing watched file descriptors using epoll_ctl) independently.
E.g. I create an epoll file descriptor A which waits for events on the files P and Q. The I copy it to epoll file descriptor B, and make B also waits for events on file R. Calling epoll_wait(A) will still only wait for P and Q.
Is this the behavior when calling dup on A, or is it needed to recreate the epoll file descriptor using epoll_create and epoll_ctl?
Aucun commentaire:
Enregistrer un commentaire