Commit e8030905 authored by Andrew Tridgell's avatar Andrew Tridgell

use the orig_umask when choosing perms for the log file.

parent 6265551a
......@@ -78,7 +78,8 @@ void log_open(void)
/* optionally use a log file instead of syslog */
logf = lp_log_file();
if (logf && *logf) {
int old_umask = umask(077);
extern int orig_umask;
int old_umask = umask(022 | orig_umask);
logfile = fopen(logf, "a");
umask(old_umask);
return;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment