From owner-freebsd-current Tue Apr 6 10: 3:57 1999 Delivered-To: freebsd-current@freebsd.org Received: from apollo.backplane.com (apollo.backplane.com [209.157.86.2]) by hub.freebsd.org (Postfix) with ESMTP id 5AEB815097 for ; Tue, 6 Apr 1999 10:03:56 -0700 (PDT) (envelope-from dillon@apollo.backplane.com) Received: (from dillon@localhost) by apollo.backplane.com (8.9.3/8.9.1) id KAA09326; Tue, 6 Apr 1999 10:01:36 -0700 (PDT) (envelope-from dillon) Date: Tue, 6 Apr 1999 10:01:36 -0700 (PDT) From: Matthew Dillon Message-Id: <199904061701.KAA09326@apollo.backplane.com> To: Ville-Pertti Keinonen Cc: current@freebsd.org Subject: Re: aio_read References: <199904051834.LAA11656@apollo.backplane.com.newsgate.clinet.fi> <86vhfam5vn.fsf@not.oeno.com> Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG : : :Matthew Dillon writes: : :> UNIX has been broken this way from day 1. It was a major design mistake. :> The only way to get your own descriptor seek offset is to open() the :> file again. : :It's not necessarily breakage. Not having any mechanism other than :open to get your own seek offset is nasty, but sharing a seek offset :can also be useful. File descriptors can't be "reverse-inherited", so :in order to continue writing to the same redirected output file, a :sequence of commands executed by a shell needs to be able to share the :actual file offset. I believe this was the original reason for the :behavior. If it's a redirected output file you simply make it O_APPEND, at which point the seek offset in the descriptor becomes irrelevant. -Matt Matthew Dillon To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message