aboutsummaryrefslogtreecommitdiffstats
path: root/lib/set-permissions.c
diff options
context:
space:
mode:
authorPaul Eggert2018-10-08 18:21:47 -0700
committerPaul Eggert2018-10-08 18:22:22 -0700
commitcf1ebfa055fcd0749aa4ed2fc4c399470b9eb3de (patch)
tree8af8b5c52560c91b2094dae951b082c370496aea /lib/set-permissions.c
parentfc6004e61760d3bd3e27b593c318e634a221652c (diff)
downloademacs-cf1ebfa055fcd0749aa4ed2fc4c399470b9eb3de.tar.gz
emacs-cf1ebfa055fcd0749aa4ed2fc4c399470b9eb3de.zip
Update from Gnulib
This incorporates: 2018-10-05 explicit_bzero: make it possible to namespace 2018-10-04 fcntl: make it possible to namespace 2018-10-01 mkostemp, mkostemps: fix C++ compilation on Mac OS X 2018-09-19 maint: mktime.c now shared with glibc 2018-09-18 file-has-acl: fix test failure on Cygwin 2.9 2018-09-18 gettime: nanotime never existed * admin/merge-gnulib (AVOIDED_MODULES): Add mkdir. * doc/misc/texinfo.tex, lib/acl-internal.c, lib/acl-internal.h: * lib/acl_entries.c, lib/explicit_bzero.c, lib/fcntl.c: * lib/get-permissions.c, lib/gettime.c, lib/mktime.c: * lib/set-permissions.c, lib/stdlib.in.h, m4/acl.m4, m4/gettime.m4: Copy from Gnulib. * lib/gnulib.mk.in: Regenerate.
Diffstat (limited to 'lib/set-permissions.c')
-rw-r--r--lib/set-permissions.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/lib/set-permissions.c b/lib/set-permissions.c
index d42335aa502..a415e133ac7 100644
--- a/lib/set-permissions.c
+++ b/lib/set-permissions.c
@@ -24,7 +24,7 @@
24#include "acl-internal.h" 24#include "acl-internal.h"
25 25
26#if USE_ACL 26#if USE_ACL
27# if ! defined HAVE_ACL_FROM_MODE && defined HAVE_ACL_FROM_TEXT /* FreeBSD, IRIX, Tru64 */ 27# if ! defined HAVE_ACL_FROM_MODE && defined HAVE_ACL_FROM_TEXT /* FreeBSD, IRIX, Tru64, Cygwin >= 2.5 */
28# if HAVE_ACL_GET_FILE && !HAVE_ACL_TYPE_EXTENDED 28# if HAVE_ACL_GET_FILE && !HAVE_ACL_TYPE_EXTENDED
29 29
30static acl_t 30static acl_t
@@ -32,7 +32,7 @@ acl_from_mode (mode_t mode)
32{ 32{
33# if HAVE_ACL_FREE_TEXT /* Tru64 */ 33# if HAVE_ACL_FREE_TEXT /* Tru64 */
34 char acl_text[] = "u::---,g::---,o::---,"; 34 char acl_text[] = "u::---,g::---,o::---,";
35# else /* FreeBSD, IRIX */ 35# else /* FreeBSD, IRIX, Cygwin >= 2.5 */
36 char acl_text[] = "u::---,g::---,o::---"; 36 char acl_text[] = "u::---,g::---,o::---";
37# endif 37# endif
38 38
@@ -51,7 +51,7 @@ acl_from_mode (mode_t mode)
51# endif 51# endif
52# endif 52# endif
53 53
54# if HAVE_FACL && defined GETACL /* Solaris, Cygwin, not HP-UX */ 54# if HAVE_FACL && defined GETACL /* Solaris, Cygwin < 2.5, not HP-UX */
55static int 55static int
56set_acls_from_mode (const char *name, int desc, mode_t mode, bool *must_chmod) 56set_acls_from_mode (const char *name, int desc, mode_t mode, bool *must_chmod)
57{ 57{
@@ -489,9 +489,9 @@ set_acls (struct permission_context *ctx, const char *name, int desc,
489 489
490# if HAVE_ACL_GET_FILE 490# if HAVE_ACL_GET_FILE
491 /* POSIX 1003.1e (draft 17 -- abandoned) specific version. */ 491 /* POSIX 1003.1e (draft 17 -- abandoned) specific version. */
492 /* Linux, FreeBSD, Mac OS X, IRIX, Tru64 */ 492 /* Linux, FreeBSD, Mac OS X, IRIX, Tru64, Cygwin >= 2.5 */
493# if !HAVE_ACL_TYPE_EXTENDED 493# if !HAVE_ACL_TYPE_EXTENDED
494 /* Linux, FreeBSD, IRIX, Tru64 */ 494 /* Linux, FreeBSD, IRIX, Tru64, Cygwin >= 2.5 */
495 495
496# ifndef HAVE_ACL_FROM_TEXT 496# ifndef HAVE_ACL_FROM_TEXT
497# error Must have acl_from_text (see POSIX 1003.1e draft 17). 497# error Must have acl_from_text (see POSIX 1003.1e draft 17).
@@ -542,14 +542,14 @@ set_acls (struct permission_context *ctx, const char *name, int desc,
542 } 542 }
543 } 543 }
544 544
545# if HAVE_ACL_TYPE_NFS4 /* FreeBSD */ 545# if HAVE_ACL_TYPE_NFS4 /* FreeBSD */
546 546
547 /* File systems either support POSIX ACLs (for example, ufs) or NFS4 ACLs 547 /* File systems either support POSIX ACLs (for example, ufs) or NFS4 ACLs
548 (for example, zfs). */ 548 (for example, zfs). */
549 549
550 /* TODO: Implement setting ACLs once get_permissions() reads them. */ 550 /* TODO: Implement setting ACLs once get_permissions() reads them. */
551 551
552# endif 552# endif
553 553
554# else /* HAVE_ACL_TYPE_EXTENDED */ 554# else /* HAVE_ACL_TYPE_EXTENDED */
555 /* Mac OS X */ 555 /* Mac OS X */