From owner-cvs-all Thu Jul 16 10:19:32 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id KAA12343 for cvs-all-outgoing; Thu, 16 Jul 1998 10:19:32 -0700 (PDT) (envelope-from owner-cvs-all@FreeBSD.ORG) Received: from freefall.freebsd.org (freefall.FreeBSD.ORG [204.216.27.21]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id KAA12334; Thu, 16 Jul 1998 10:19:28 -0700 (PDT) (envelope-from nate@FreeBSD.org) From: Nate Williams Received: (from nate@localhost) by freefall.freebsd.org (8.8.8/8.8.5) id KAA05890; Thu, 16 Jul 1998 10:18:31 -0700 (PDT) Date: Thu, 16 Jul 1998 10:18:31 -0700 (PDT) Message-Id: <199807161718.KAA05890@freefall.freebsd.org> To: cvs-committers@FreeBSD.ORG, cvs-all@FreeBSD.ORG, cvs-usrsbin@FreeBSD.ORG Subject: cvs commit: src/usr.sbin/pw edgroup.c fileupd.c pw.c Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk nate 1998/07/16 10:18:30 PDT Modified files: usr.sbin/pw edgroup.c fileupd.c pw.c Log: Fix race condition in pw caused by multiple instances of pwd_mkdb being run at the same time. Notes: The fileupdate function is still somewhat broken. Instead of returning a failure code if it can't modify the original file it renames the .new file and continues as though nothing is wrong. This will cause the lock on the original file to be lost and could lead to a similar race condition. I left that portion of the code alone since I feel that the maintainer of the code would have a better concept of how he wants to handle errors in that function than I do. PR: bin/6787 Submitted by: Craig Spannring Revision Changes Path 1.6 +2 -2 src/usr.sbin/pw/edgroup.c 1.6 +14 -3 src/usr.sbin/pw/fileupd.c 1.8 +23 -2 src/usr.sbin/pw/pw.c To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message