From owner-freebsd-arch Fri Oct 26 14:23:21 2001 Delivered-To: freebsd-arch@freebsd.org Received: from mail-blue.research.att.com (mail-blue.research.att.com [135.207.30.102]) by hub.freebsd.org (Postfix) with ESMTP id A59E237B408; Fri, 26 Oct 2001 14:23:19 -0700 (PDT) Received: from alliance.research.att.com (alliance.research.att.com [135.207.26.26]) by mail-blue.research.att.com (Postfix) with ESMTP id E84404CE42; Fri, 26 Oct 2001 17:23:18 -0400 (EDT) Received: from windsor.research.att.com (windsor.research.att.com [135.207.26.46]) by alliance.research.att.com (8.8.7/8.8.7) with ESMTP id RAA24510; Fri, 26 Oct 2001 17:23:18 -0400 (EDT) From: Bill Fenner Received: (from fenner@localhost) by windsor.research.att.com (8.8.8+Sun/8.8.5) id OAA13087; Fri, 26 Oct 2001 14:23:17 -0700 (PDT) Message-Id: <200110262123.OAA13087@windsor.research.att.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII To: bde@zeta.org.au Subject: Re: Behavior of select() on pipes Cc: rwatson@freebsd.org, bright@mu.org, arch@freebsd.org Date: Fri, 26 Oct 2001 14:23:17 -0700 Versions: dmail (solaris) 2.2j/makemail 2.9b Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Yes, it's a shame that the description of select() carefully covers this case and it's completely missing from poll(). >> Perhaps we can carefully interpret "an empty .. FIFO" to exclude the >> time before the first writer opens it. Maybe during that time it's not >> empty, it's untenanted. > >Ugh. It makes sense for the state not to depend on previous activity. >It reduces the effect of races. But the standard behavior makes O_NONBLOCK FIFOs relatively useless; once you open it for read you have no way to find out when a writer arrives without blocking. You have to become a writer yourself, which may limit the usefulness of permissions on the FIFO (e.g. an rw-r----- FIFO for messages from fenner to group foo; anyone in group foo could become the reader but it's impossible for them to open for writing to get around this behavior). Bill To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message