CVSROOT:        /cvs
Module name:    src
Changes by:     mill...@cvs.openbsd.org 2014/10/09 10:36:36

Modified files:
        sys/miscfs/fifofs: fifo_vnops.c 

Log message:
Instead of trying to emulate select/poll semantics with respect to EOF
by mutating so_state before calling soo_poll(), call soo_poll() normally
but avoid setting SS_CANTRCVMORE in the reader's so_state on first open.
This fixes EOF detection in select/poll on the reader side when the write
side is closed.  Also set SS_ISDISCONNECTED when the writer count reaches
zero so POLLHUP is set in revents.  Unlike Unix domain sockets, we need
to clear the EOF indicator after it has been read so that subsequent
reads will block waiting for a new writer.  This now passes regress.

Reply via email to