diff options
author | trasz <trasz@FreeBSD.org> | 2009-12-26 11:36:10 +0000 |
---|---|---|
committer | trasz <trasz@FreeBSD.org> | 2009-12-26 11:36:10 +0000 |
commit | a78d6a0fdab8ef9df3cfbb1d0b47b6f76cb8a71c (patch) | |
tree | afe50feb8570f29e5e5ee7379ef96a8bd309abfb /sys/kern/subr_acl_posix1e.c | |
parent | 690bd6b42878a547aceee0005d5124b3a0a81c04 (diff) | |
download | FreeBSD-src-a78d6a0fdab8ef9df3cfbb1d0b47b6f76cb8a71c.zip FreeBSD-src-a78d6a0fdab8ef9df3cfbb1d0b47b6f76cb8a71c.tar.gz |
Now that all the callers seem to be fixed, add KASSERTs to make sure VAPPEND
is not being used improperly.
Diffstat (limited to 'sys/kern/subr_acl_posix1e.c')
-rw-r--r-- | sys/kern/subr_acl_posix1e.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/sys/kern/subr_acl_posix1e.c b/sys/kern/subr_acl_posix1e.c index 9690580..600067c 100644 --- a/sys/kern/subr_acl_posix1e.c +++ b/sys/kern/subr_acl_posix1e.c @@ -63,6 +63,8 @@ vaccess_acl_posix1e(enum vtype type, uid_t file_uid, gid_t file_gid, KASSERT((accmode & ~(VEXEC | VWRITE | VREAD | VADMIN | VAPPEND)) == 0, ("invalid bit in accmode")); + KASSERT((accmode & VAPPEND) == 0 || (accmode & VWRITE), + ("VAPPEND without VWRITE")); /* * Look for a normal, non-privileged way to access the file/directory |