From 0152c542e856249268e30b55beb2749bc2ed161a Mon Sep 17 00:00:00 2001 From: bad Date: Sun, 2 Aug 2009 20:44:55 +0000 Subject: [PATCH] Add a note to change_root() that the callers need to authorize the operation. As requested by elad@. --- sys/kern/vfs_syscalls.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/sys/kern/vfs_syscalls.c b/sys/kern/vfs_syscalls.c index 8cba49b3a23a..a5a7a1299926 100644 --- a/sys/kern/vfs_syscalls.c +++ b/sys/kern/vfs_syscalls.c @@ -1,4 +1,4 @@ -/* $NetBSD: vfs_syscalls.c,v 1.397 2009/08/01 21:17:11 bad Exp $ */ +/* $NetBSD: vfs_syscalls.c,v 1.398 2009/08/02 20:44:55 bad Exp $ */ /*- * Copyright (c) 2008, 2009 The NetBSD Foundation, Inc. @@ -66,7 +66,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: vfs_syscalls.c,v 1.397 2009/08/01 21:17:11 bad Exp $"); +__KERNEL_RCSID(0, "$NetBSD: vfs_syscalls.c,v 1.398 2009/08/02 20:44:55 bad Exp $"); #ifdef _KERNEL_OPT #include "opt_fileassoc.h" @@ -1207,6 +1207,7 @@ sys_chroot(struct lwp *l, const struct sys_chroot_args *uap, register_t *retval) /* * Common routine for chroot and fchroot. + * NB: callers need to properly authorize the change root operation. */ void change_root(struct cwdinfo *cwdi, struct vnode *vp, struct lwp *l)