From owner-freebsd-bugs Fri Dec 27 01:30:03 1996 Return-Path: Received: (from root@localhost) by freefall.freebsd.org (8.8.4/8.8.4) id BAA11849 for bugs-outgoing; Fri, 27 Dec 1996 01:30:03 -0800 (PST) Received: (from gnats@localhost) by freefall.freebsd.org (8.8.4/8.8.4) id BAA11843; Fri, 27 Dec 1996 01:30:01 -0800 (PST) Date: Fri, 27 Dec 1996 01:30:01 -0800 (PST) Message-Id: <199612270930.BAA11843@freefall.freebsd.org> To: freebsd-bugs Cc: From: Matthew Dillon Subject: Re: bin/2291: Race condition in pw_lock (vipw, chpass, etc....) Reply-To: Matthew Dillon Sender: owner-bugs@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk The following reply was made to PR bin/2291; it has been noted by GNATS. From: Matthew Dillon To: joerg_wunsch@uriah.heep.sax.de (Joerg Wunsch) Cc: FreeBSD-gnats-submit@freebsd.org Subject: Re: bin/2291: Race condition in pw_lock (vipw, chpass, etc....) Date: Fri, 27 Dec 1996 01:21:07 -0800 (PST) : :Why not using the O_EXLOCK flag in open(2)? : :-- :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. ;-) I don't think O_EXLOCK avoids the rename()-over race condition... you still have to do the stat()/fstat() check afterwords. -Matt Matthew Dillon Engineering, BEST Internet Communications, Inc. [always include a portion of the original email in any response!]