From 438835cabb95a758042ff249cbd5840727eaf9bd Mon Sep 17 00:00:00 2001 From: rwatson Date: Sun, 20 Oct 2002 22:08:26 +0000 Subject: Implement _POSIX_ACL_PATH_MAX, which returns the maximum number of ACL entries for a file system node using pathconf(). Obtained from: TrustedBSD Project Sponsored by: DARPA, Network Associates Laboratories --- sys/ufs/ufs/ufs_vnops.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/sys/ufs/ufs/ufs_vnops.c b/sys/ufs/ufs/ufs_vnops.c index 2aad545..739ec66 100644 --- a/sys/ufs/ufs/ufs_vnops.c +++ b/sys/ufs/ufs/ufs_vnops.c @@ -2198,6 +2198,16 @@ ufs_pathconf(ap) *ap->a_retval = 0; #endif return (0); + case _POSIX_ACL_PATH_MAX: +#ifdef UFS_ACL + if (ap->a_vp->v_mount->mnt_flag & MNT_ACLS) + *ap->a_retval = ACL_MAX_ENTRIES; + else + *ap->a_retval = 3; +#else + *ap->a_retval = 3; +#endif + return (0); case _POSIX_MAC_PRESENT: #ifdef MAC if (ap->a_vp->v_mount->mnt_flag & MNT_MULTILABEL) -- cgit v1.1