Date: Fri, 9 Nov 2001 20:52:36 +1100 (EST) From: Bruce Evans <bde@zeta.org.au> To: Alfred Perlstein <alfred@FreeBSD.org> Cc: <cvs-committers@FreeBSD.org>, <cvs-all@FreeBSD.org> Subject: Re: cvs commit: src/sys/fs/fifofs fifo_vnops.c Message-ID: <20011109201311.M9053-100000@delplex.bde.org> In-Reply-To: <200111081028.fA8ASW132591@freefall.freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, 8 Nov 2001, Alfred Perlstein wrote: > alfred 2001/11/08 02:28:32 PST > > Modified files: > sys/fs/fifofs fifo_vnops.c > Log: > Switch behavior of fifos to more closely match what goes on in other OSes. > Basically FIFOs become a real pain to abuse as a rendevous point without > this change because you can't really select(2) on them because they always > return ready even though there is no writer (to signal EOF). > > Obtained from: BSD/os PR: 19871 > > Revision Changes Path > 1.56 +6 -1 src/sys/fs/fifofs/fifo_vnops.c Arrgh. I thought you agreed with my mail saying that POSIX doesn't permit "fix"ing select(): > On Thu, 25 Oct 2001 alfred@FreeBSD.ORG wrote: > > > Synopsis: select on named pipes always returns 'available for reading' > > > > Responsible-Changed-From-To: freebsd-bugs->alfred > > Responsible-Changed-By: alfred > > Responsible-Changed-When: Thu Oct 25 17:38:21 PDT 2001 > > Responsible-Changed-Why: > > I'll take care of this. > > This can be closed now. See Bill Fenner's quote of POSIX.1-200x. > > Bruce This commit is much wronger than anything we discussed: 1) It doesn't actually "fix" select(), since SS_CANTRCVMORE is still set after the first (non-blocking) open when there are no writers. IIRC, this is the case that the PR requested fixing. It was certainly the only case that we seriously considered "fixing". 2) It breaks read() in all cases where there is no data and no writers, except in the case not "fixed" in (1). You didn't have to go to BSD/os (sic) to obtain this breakage. It could have been obtained by clobbering the part of rev.1.40 that fixed read() on fifos. Backing out all of rev.1.40 would also have given broken breakage for case (1). Please back this out. Bruce To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20011109201311.M9053-100000>