diff options
Diffstat (limited to 'sys/cddl/compat/opensolaris')
-rw-r--r-- | sys/cddl/compat/opensolaris/kern/opensolaris_policy.c | 8 | ||||
-rw-r--r-- | sys/cddl/compat/opensolaris/sys/policy.h | 2 |
2 files changed, 5 insertions, 5 deletions
diff --git a/sys/cddl/compat/opensolaris/kern/opensolaris_policy.c b/sys/cddl/compat/opensolaris/kern/opensolaris_policy.c index a09c9ec..272fe59 100644 --- a/sys/cddl/compat/opensolaris/kern/opensolaris_policy.c +++ b/sys/cddl/compat/opensolaris/kern/opensolaris_policy.c @@ -91,17 +91,17 @@ secpolicy_vnode_remove(struct ucred *cred) int secpolicy_vnode_access(struct ucred *cred, struct vnode *vp, uint64_t owner, - int mode) + accmode_t accmode) { - if ((mode & VREAD) && priv_check_cred(cred, PRIV_VFS_READ, 0) != 0) { + if ((accmode & VREAD) && priv_check_cred(cred, PRIV_VFS_READ, 0) != 0) { return (EACCES); } - if ((mode & VWRITE) && + if ((accmode & VWRITE) && priv_check_cred(cred, PRIV_VFS_WRITE, 0) != 0) { return (EACCES); } - if (mode & VEXEC) { + if (accmode & VEXEC) { if (vp->v_type == VDIR) { if (priv_check_cred(cred, PRIV_VFS_LOOKUP, 0) != 0) { return (EACCES); diff --git a/sys/cddl/compat/opensolaris/sys/policy.h b/sys/cddl/compat/opensolaris/sys/policy.h index 50d3fd8..2c764ef 100644 --- a/sys/cddl/compat/opensolaris/sys/policy.h +++ b/sys/cddl/compat/opensolaris/sys/policy.h @@ -46,7 +46,7 @@ int secpolicy_basic_link(struct ucred *cred); int secpolicy_vnode_stky_modify(struct ucred *cred); int secpolicy_vnode_remove(struct ucred *cred); int secpolicy_vnode_access(struct ucred *cred, struct vnode *vp, - uint64_t owner, int mode); + uint64_t owner, accmode_t accmode); int secpolicy_vnode_setdac(struct ucred *cred, uid_t owner); int secpolicy_vnode_setattr(struct ucred *cred, struct vnode *vp, struct vattr *vap, const struct vattr *ovap, int flags, |