From owner-freebsd-bugs Thu Jul 18 12:52:05 1996 Return-Path: owner-bugs Received: (from root@localhost) by freefall.freebsd.org (8.7.5/8.7.3) id MAA12155 for bugs-outgoing; Thu, 18 Jul 1996 12:52:05 -0700 (PDT) Received: from irz301.inf.tu-dresden.de (irz301.inf.tu-dresden.de [141.76.1.11]) by freefall.freebsd.org (8.7.5/8.7.3) with SMTP id MAA12130 for ; Thu, 18 Jul 1996 12:51:59 -0700 (PDT) Received: from sax.sax.de by irz301.inf.tu-dresden.de (8.6.12/8.6.12-s1) with ESMTP id VAA06345; Thu, 18 Jul 1996 21:51:09 +0200 Received: (from uucp@localhost) by sax.sax.de (8.6.12/8.6.12-s1) with UUCP id VAA27546; Thu, 18 Jul 1996 21:51:09 +0200 Received: (from j@localhost) by uriah.heep.sax.de (8.7.5/8.6.9) id VAA07250; Thu, 18 Jul 1996 21:46:33 +0200 (MET DST) From: J Wunsch Message-Id: <199607181946.VAA07250@uriah.heep.sax.de> Subject: Re: kern/1397: can't send to a pipe To: wpaul@skynet.ctr.columbia.edu (Bill Paul) Date: Thu, 18 Jul 1996 21:46:33 +0200 (MET DST) Cc: markd@Grizzly.COM, bugs@freefall.freebsd.org Reply-To: joerg_wunsch@uriah.heep.sax.de (Joerg Wunsch) In-Reply-To: <199607181825.OAA14569@skynet.ctr.columbia.edu> from Bill Paul at "Jul 18, 96 02:25:00 pm" X-Phone: +49-351-2012 669 X-PGP-Fingerprint: DC 47 E6 E4 FF A6 E9 8F 93 21 E0 7D F9 12 D6 4E X-Mailer: ELM [version 2.4ME+ PL17 (25)] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-bugs@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk As Bill Paul wrote: > He didn't mean fstat(1), he meant fstat(2). Look at the sample source Errm yep. > In this case, he could replace pipe(2) with socketpair(2) in the > application, but that doesn't change the fact that fstat(2) is reporting > a bogus result. I suppose a new type has to be added (S_IPIPE?), but > a question (in my mind at least) of compatibility with other *BSD systems. BUGS Applying fstat() to a socket (and thus to a pipe) returns a zeroed buffer, except for the blocksize field, and a unique device and inode number. So there's a bug in the BUGS section in that the st_mode field is also being set. Anyway, nobody could rely on it... ;-) -- cheers, J"org joerg_wunsch@uriah.heep.sax.de -- http://www.sax.de/~joerg/ -- NIC: JW11-RIPE Never trust an operating system you don't have sources for. ;-)