Commit 771fe316ce8041663a84fdb38ccc7419e6231e0c

Paul Eggert 2024-11-11T07:35:50

file-has-acl: scontext even if --disable-acl Be able to get the security context even if configured with --disable-acl, as security contexts are not ACLs, and the main reason for --disable-acl was for efficiency with GNU ls -l, a concern that does not apply to security contexts (which are needed only with ls -Z). Problem reported by Pádraig Brady <https://bugs.gnu.org/73418#52>. * lib/acl.h (ACL_GET_SCONTEXT): New constant. (aclinfo_free, aclinfo_scontext_free): Declare even if !USE_ACL. * lib/file-has-acl.c (USE_LINUX_XATTR): No longer false merely because !USE_ACL, because we need xattr to get scontext. (get_aclinfo): Support new ACL_GET_SCONTEXT flag.