Date: Sat, 30 Jan 2010 19:26:35 +0000 (UTC) From: Robert Watson <rwatson@FreeBSD.org> To: src-committers@freebsd.org, svn-src-projects@freebsd.org Subject: svn commit: r203222 - projects/capabilities8/sys/kern Message-ID: <201001301926.o0UJQZ70085197@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: rwatson Date: Sat Jan 30 19:26:34 2010 New Revision: 203222 URL: http://svn.freebsd.org/changeset/base/203222 Log: Merge c171327 from the p4 TrustedBSD Capabilities branch to capabilities8: We should, of course, be setting *base to 0, not the local variable base. Submitted by: Jonathan Anderson <jonathan.anderson at cl.cam.ac.uk> Modified: projects/capabilities8/sys/kern/vfs_syscalls.c Modified: projects/capabilities8/sys/kern/vfs_syscalls.c ============================================================================== --- projects/capabilities8/sys/kern/vfs_syscalls.c Sat Jan 30 19:26:28 2010 (r203221) +++ projects/capabilities8/sys/kern/vfs_syscalls.c Sat Jan 30 19:26:34 2010 (r203222) @@ -165,7 +165,7 @@ getvnode_cap(struct filedesc *fdp, int f * Several *at() system calls are now supported in capability mode. This function * finds out what their "*at base" vnode, which is needed by namei(), should be: * - * 1. In non-capability (and thus unconstrained) mode, base = 0. + * 1. In non-capability (and thus unconstrained) mode, *base = 0. * 2. In capability mode, base is the vnode given by the fd parameter, subject to * the condition that the supplied 'rights' parameter (OR'ed with CAP_LOOKUP * and CAP_ATBASE) is satisfied. The vnode is returned with a shared lock. @@ -174,7 +174,7 @@ int fgetbase(struct thread *td, int fd, cap_rights_t rights, struct vnode **base) { if (!(td->td_ucred->cr_flags & CRED_FLAG_CAPMODE)) - base = 0; + *base = 0; else { int error;
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201001301926.o0UJQZ70085197>