summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAmy Winston <amynka@gentoo.org>2016-11-06 20:08:45 +0100
committerAmy Winston <amynka@gentoo.org>2016-11-06 20:13:23 +0100
commit5fda0962579cd0d6ec0e7ebf22bec1b4685be0bd (patch)
treede68c7bdb578d5e0c451bda8300a2adcbd91aebe /dev-scheme/guile/files
parentdev-libs/icu-le-hb: Add office project to maintainers (diff)
downloadgentoo-5fda0962579cd0d6ec0e7ebf22bec1b4685be0bd.tar.gz
gentoo-5fda0962579cd0d6ec0e7ebf22bec1b4685be0bd.tar.bz2
gentoo-5fda0962579cd0d6ec0e7ebf22bec1b4685be0bd.zip
dev-scheme/guile: add unmask patch bug #596864
Package-Manager: portage-2.3.0
Diffstat (limited to 'dev-scheme/guile/files')
-rw-r--r--dev-scheme/guile/files/guile-1.8.8-mkdir-mask.patch35
1 files changed, 35 insertions, 0 deletions
diff --git a/dev-scheme/guile/files/guile-1.8.8-mkdir-mask.patch b/dev-scheme/guile/files/guile-1.8.8-mkdir-mask.patch
new file mode 100644
index 000000000000..7d1c703835f1
--- /dev/null
+++ b/dev-scheme/guile/files/guile-1.8.8-mkdir-mask.patch
@@ -0,0 +1,35 @@
+--- a/libguile/filesys.c 2016-11-05 15:03:52.131894648 +0100
++++ b/libguile/filesys.c 2016-11-05 15:07:13.275894481 +0100
+@@ -791,24 +791,18 @@
+ SCM_DEFINE (scm_mkdir, "mkdir", 1, 1, 0,
+ (SCM path, SCM mode),
+ "Create a new directory named by @var{path}. If @var{mode} is omitted\n"
+- "then the permissions of the directory file are set using the current\n"
+- "umask. Otherwise they are set to the decimal value specified with\n"
+- "@var{mode}. The return value is unspecified.")
++ "then the permissions of the directory are set to @code{#o777}\n"
++ "masked with the current umask (@pxref{Processes, @code{umask}}).\n"
++ "Otherwise they are set to the value specified with @var{mode}.\n"
++ "The return value is unspecified.")
+ #define FUNC_NAME s_scm_mkdir
+ {
+ int rv;
+- mode_t mask;
++ mode_t c_mode;
+
+- if (SCM_UNBNDP (mode))
+- {
+- mask = umask (0);
+- umask (mask);
+- STRING_SYSCALL (path, c_path, rv = mkdir (c_path, 0777 ^ mask));
+- }
+- else
+- {
+- STRING_SYSCALL (path, c_path, rv = mkdir (c_path, scm_to_uint (mode)));
+- }
++ c_mode = SCM_UNBNDP (mode) ? 0777 : scm_to_uint (mode);
++
++ STRING_SYSCALL (path, c_path, rv = mkdir (c_path, c_mode));
+ if (rv != 0)
+ SCM_SYSERROR;
+ return SCM_UNSPECIFIED;