]> git.pld-linux.org Git - packages/dlm.git/blobdiff - dlm-perms.patch
Version: 4.0.0
[packages/dlm.git] / dlm-perms.patch
diff --git a/dlm-perms.patch b/dlm-perms.patch
new file mode 100644 (file)
index 0000000..26208de
--- /dev/null
@@ -0,0 +1,33 @@
+From f15a2daed7137481c7161e1447b1796c308c7e08 Mon Sep 17 00:00:00 2001
+From: David Teigland <teigland@redhat.com>
+Date: Tue, 06 Nov 2012 21:40:00 +0000
+Subject: dlm_controld: fix modes for run dir and file
+
+dir should be 775 and file 644
+
+Signed-off-by: David Teigland <teigland@redhat.com>
+---
+diff --git a/dlm_controld/main.c b/dlm_controld/main.c
+index 91fbc4f..a68e1b8 100644
+--- a/dlm_controld/main.c
++++ b/dlm_controld/main.c
+@@ -1107,7 +1107,7 @@ static int lockfile(const char *dir, const char *name)
+       int fd, rv;
+       old_umask = umask(0022);
+-      rv = mkdir(dir, 0777);
++      rv = mkdir(dir, 0775);
+       if (rv < 0 && errno != EEXIST) {
+               umask(old_umask);
+               return rv;
+@@ -1116,7 +1116,7 @@ static int lockfile(const char *dir, const char *name)
+       snprintf(path, PATH_MAX, "%s/%s", dir, name);
+-      fd = open(path, O_CREAT|O_WRONLY|O_CLOEXEC, 0666);
++      fd = open(path, O_CREAT|O_WRONLY|O_CLOEXEC, 0644);
+       if (fd < 0) {
+               log_error("lockfile open error %s: %s",
+                         path, strerror(errno));
+--
+cgit v0.9.0.3
This page took 0.028896 seconds and 4 git commands to generate.