From 171e856ec8a0a64504b4b4a47ab6181d37fc3dbe Mon Sep 17 00:00:00 2001 From: Mike Gilbert Date: Wed, 16 Mar 2016 10:25:27 -0400 Subject: start-stop-daemon: Allow group read/write when creating output files This allows for better interaction with inherited ACL entries. This fixes #84. X-Gentoo-Bug: 577362 X-Gentoo-Bug-URL: https://bugs.gentoo.org/577362 --- src/rc/start-stop-daemon.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/rc/start-stop-daemon.c b/src/rc/start-stop-daemon.c index 775bd7de..8ed3e923 100644 --- a/src/rc/start-stop-daemon.c +++ b/src/rc/start-stop-daemon.c @@ -1242,7 +1242,7 @@ int main(int argc, char **argv) if (redirect_stdout) { if ((stdout_fd = open(redirect_stdout, O_WRONLY | O_CREAT | O_APPEND, - S_IRUSR | S_IWUSR)) == -1) + S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP)) == -1) eerrorx("%s: unable to open the logfile" " for stdout `%s': %s", applet, redirect_stdout, strerror(errno)); @@ -1250,7 +1250,7 @@ int main(int argc, char **argv) if (redirect_stderr) { if ((stderr_fd = open(redirect_stderr, O_WRONLY | O_CREAT | O_APPEND, - S_IRUSR | S_IWUSR)) == -1) + S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP)) == -1) eerrorx("%s: unable to open the logfile" " for stderr `%s': %s", applet, redirect_stderr, strerror(errno)); -- cgit v1.2.3