From owner-cvs-all Fri Jul 12 21: 7:17 2002 Delivered-To: cvs-all@freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 9AE9D37B400; Fri, 12 Jul 2002 21:07:13 -0700 (PDT) Received: from freefall.freebsd.org (freefall.FreeBSD.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4EE7E43E58; Fri, 12 Jul 2002 21:07:13 -0700 (PDT) (envelope-from jhb@FreeBSD.org) Received: from freefall.freebsd.org (jhb@localhost [127.0.0.1]) by freefall.freebsd.org (8.12.4/8.12.4) with ESMTP id g6D47DJU072418; Fri, 12 Jul 2002 21:07:13 -0700 (PDT) (envelope-from jhb@freefall.freebsd.org) Received: (from jhb@localhost) by freefall.freebsd.org (8.12.4/8.12.4/Submit) id g6D47Dkv072417; Fri, 12 Jul 2002 21:07:13 -0700 (PDT) Message-Id: <200207130407.g6D47Dkv072417@freefall.freebsd.org> From: John Baldwin Date: Fri, 12 Jul 2002 21:07:12 -0700 (PDT) To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: cvs commit: src/sys/kern vfs_syscalls.c X-FreeBSD-CVS-Branch: HEAD Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG jhb 2002/07/12 21:07:12 PDT Modified files: sys/kern vfs_syscalls.c Log: - Change chroot_refuse_vdir_fds() to require that the passed in struct filedesc is already locked rather than having chroot() unlock the filedesc so chroot_refuse_vdir_fds() can immediately relock it. - Reorder chroot() a bitso that we do the namei lookup before checking the process's struct filedesc. This closes at least one potential race and allows us to only acquire the filedsec lock once in chroot(). - Push down Giant slightly into chroot(). Revision Changes Path 1.268 +18 -16 src/sys/kern/vfs_syscalls.c To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message