if ((ap->a_ioflag & IO_NDELAY) && error == EWOULDBLOCK && ap->a_vp->v_fifoinfo->fi_writers == 0) error = 0;
if (error == EWOULDBLOCK && ap->a_vp->v_fifoinfo->fi_writers == 0) error = 0; }
fifo_read(v)	void *v;{	struct vop_read_args /* {		struct vnode *a_vp;		struct uio *a_uio;		int  a_ioflag;		struct ucred *a_cred;	} */ *ap = v;	register struct uio *uio = ap->a_uio;	register struct socket *rso = ap->a_vp->v_fifoinfo->fi_readsock;	struct proc *p = uio->uio_procp;	int error, startresid;#ifdef DIAGNOSTIC	if (uio->uio_rw != UIO_READ)		panic("fifo_read mode");#endif	if (uio->uio_resid == 0)		return (0);	if (ap->a_ioflag & IO_NDELAY)		rso->so_state |= SS_NBIO;	startresid = uio->uio_resid;	VOP_UNLOCK(ap->a_vp, 0, p);	error = soreceive(rso, (struct mbuf **)0, uio, (struct mbuf **)0,	    (struct mbuf **)0, (int *)0);	vn_lock(ap->a_vp, LK_EXCLUSIVE | LK_RETRY, p);	/*	 * Clear EOF indication after first such return.	 */	if (uio->uio_resid == startresid)		rso->so_state &= ~SS_CANTRCVMORE;	if (ap->a_ioflag & IO_NDELAY)		rso->so_state &= ~SS_NBIO;	if ((ap->a_ioflag & IO_NDELAY) && error == EWOULDBLOCK &&	    ap->a_vp->v_fifoinfo->fi_writers == 0)		error = 0;	return (error);}