poll()-ing a pipe descriptor, watching for POLLHUP

Vlad Galu dudu at dudu.ro
Wed Jun 3 12:25:37 UTC 2009


Hm, according to the code at
http://www.greenend.org.uk/rjk/2001/06/poll.html, it seems to work as
expected (returning both POLLIN and POLLHUP), when closing the write
end of the pipe from within the same process.


On Wed, Jun 3, 2009 at 3:15 PM, Vlad Galu <dudu at dudu.ro> wrote:
> Hello,
>
> Please take a look at the attached code. Shouldn't poll() get a
> POLLHUP event when the child process exits, closing the write end of
> the pipe?
>
> Thanks,
> Vlad
>


More information about the freebsd-stable mailing list