+2025-11-05 Bruno Haible <bruno@clisp.org>
+
+ acl-permissions: Fix compilation error (regression 2025-09-10).
+ Reported by Eli Zaretskii <eliz@gnu.org> in
+ <https://lists.gnu.org/archive/html/emacs-devel/2025-11/msg00155.html>.
+ * lib/acl_entries.c (acl_entries): Restore a #if, mistakenly removed on
+ 2025-09-10.
+
2025-11-04 Collin Funk <collin.funk1@gmail.com>
nproc: Fix compilation error with Android API ≤ 20.
#include "acl-internal.h"
/* This file assumes POSIX-draft like ACLs
- (Linux, FreeBSD, NetBSD >= 10, Mac OS X, Cygwin >= 2.5). */
+ (Linux, FreeBSD, NetBSD >= 10, Mac OS X, Cygwin >= 2.5).
+
+ It is compiled only on systems that do not have the acl_entries() function
+ (in libc or libacl). */
/* Return the number of entries in ACL.
Return -1 and set errno upon failure to determine it. */
if (acl != NULL)
{
-#if HAVE_ACL_TYPE_EXTENDED /* Mac OS X */
+#if HAVE_ACL_FIRST_ENTRY /* Linux, FreeBSD, NetBSD >= 10, Mac OS X, Cygwin >= 2.5 */
+# if HAVE_ACL_TYPE_EXTENDED /* Mac OS X */
/* acl_get_entry returns 0 when it successfully fetches an entry,
and -1/EINVAL at the end. */
acl_entry_t ace;
got_one >= 0;
got_one = acl_get_entry (acl, ACL_NEXT_ENTRY, &ace))
count++;
-#else /* Linux, FreeBSD, NetBSD >= 10, Cygwin >= 2.5 */
+# else /* Linux, FreeBSD, NetBSD >= 10, Cygwin >= 2.5 */
/* acl_get_entry returns 1 when it successfully fetches an entry,
and 0 at the end. */
acl_entry_t ace;
count++;
if (got_one < 0)
return -1;
+# endif
#endif
}