diff options
author | bde <bde@FreeBSD.org> | 2001-03-20 09:38:05 +0000 |
---|---|---|
committer | bde <bde@FreeBSD.org> | 2001-03-20 09:38:05 +0000 |
commit | a18da66f92ea26572e1921ae83af1eb794d51071 (patch) | |
tree | 905a15cf540c5f1671fef7065fb7f7337aa05c4b /sys/kern | |
parent | 67335696378a62bbff3cb190ec58b9cd673203ca (diff) | |
download | FreeBSD-src-a18da66f92ea26572e1921ae83af1eb794d51071.zip FreeBSD-src-a18da66f92ea26572e1921ae83af1eb794d51071.tar.gz |
Fixed breakage of access() in rev.1.164. Wrong credentials were used for
the final path component.
Diffstat (limited to 'sys/kern')
-rw-r--r-- | sys/kern/vfs_extattr.c | 2 | ||||
-rw-r--r-- | sys/kern/vfs_syscalls.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/sys/kern/vfs_extattr.c b/sys/kern/vfs_extattr.c index 024b50e..88c9cb7 100644 --- a/sys/kern/vfs_extattr.c +++ b/sys/kern/vfs_extattr.c @@ -1729,7 +1729,7 @@ access(p, uap) if (SCARG(uap, flags) & X_OK) flags |= VEXEC; if ((flags & VWRITE) == 0 || (error = vn_writechk(vp)) == 0) - error = VOP_ACCESS(vp, flags, cred, p); + error = VOP_ACCESS(vp, flags, tmpcred, p); } NDFREE(&nd, NDF_ONLY_PNBUF); vput(vp); diff --git a/sys/kern/vfs_syscalls.c b/sys/kern/vfs_syscalls.c index 024b50e..88c9cb7 100644 --- a/sys/kern/vfs_syscalls.c +++ b/sys/kern/vfs_syscalls.c @@ -1729,7 +1729,7 @@ access(p, uap) if (SCARG(uap, flags) & X_OK) flags |= VEXEC; if ((flags & VWRITE) == 0 || (error = vn_writechk(vp)) == 0) - error = VOP_ACCESS(vp, flags, cred, p); + error = VOP_ACCESS(vp, flags, tmpcred, p); } NDFREE(&nd, NDF_ONLY_PNBUF); vput(vp); |