From mboxrd@z Thu Jan 1 00:00:00 1970 From: "H. Peter Anvin" Subject: Re: [PATCH] LSM file locking patch is bogus Date: 8 Aug 2002 20:59:59 -0700 Sender: linux-fsdevel-owner@vger.kernel.org Message-ID: References: <20020727200221.C15614@wirex.com> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7BIT Return-path: Received: (from root@localhost) by neon-gw.transmeta.com (8.9.3/8.9.3) id VAA26092 for ; Thu, 8 Aug 2002 21:00:16 -0700 Received: from palladium.transmeta.com (palladium.transmeta.com [10.1.1.46]) by deepthought.transmeta.com (8.11.6/8.11.6) with ESMTP id g79402j16403 for ; Thu, 8 Aug 2002 21:00:02 -0700 (PDT) Received: (from mail@localhost) by palladium.transmeta.com (8.9.3/8.9.3) id VAA00974 for linux-fsdevel@vger.kernel.org; Thu, 8 Aug 2002 21:00:02 -0700 To: linux-fsdevel@vger.kernel.org List-Id: linux-fsdevel.vger.kernel.org Followup to: By author: Linus Torvalds In newsgroup: linux.dev.fs.devel > > This should be a non-issue, since current 2.5.x passes the "struct file" > pointer around, not the file descriptor. So there should be no race, > because everybody uses the same "struct file *" everywhere, and nobody > re-gets the file pointer twice any more. > > (Yeah, I'm too lazy to double-check that this is 100% true, but it > _should_ all have been fixed a few weeks ago). > Does that mean that opening /proc/*/fd/* actually dup()s the file descriptor as one should expect? -hpa -- at work, in private! "Unix gives you enough rope to shoot yourself in the foot." http://www.zytor.com/~hpa/puzzle.txt