Re: Fw: epoll and fork()

From: Chris Friesen
Date: Tue Mar 02 2004 - 10:28:10 EST


Davide Libenzi wrote:

Sorry but what behaviour do you expect by unregistering an fd pushed by the parent from inside a child? Events work exactly the same. Since the context is shared, events are delivered only once.

For principle of least surprise, I would expect that the refcounts would be bumped up so that the child could deregister without affecting the parent.

Closing the fd in the child doesn't affect the fd in the parent. Removing an fd from an fd_set in the child doesn't affect the fd_set in the parent. Unregistering an fd from an epoll set in the child shouldn't affect the parent either.

Chris

--
Chris Friesen | MailStop: 043/33/F10
Nortel Networks | work: (613) 765-0557
3500 Carling Avenue | fax: (613) 765-2986
Nepean, ON K2H 8E9 Canada | email: cfriesen@xxxxxxxxxxxxxxxxxx

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/