mdeliver: force mode 0600 for pipes (BSD gives 0000 here by default)

pull/155/head
Leah Neukirchen 5 years ago
parent 5a2c6747b6
commit 6645e80324

@ -88,6 +88,8 @@ tryagain:
struct stat st;
if (fstat(fileno(infile), &st) < 0)
st.st_mode = 0600;
if (S_ISFIFO(st.st_mode))
st.st_mode = 0600;
outfd = open(tmp, O_CREAT | O_WRONLY | O_EXCL,
st.st_mode & 07777);
if (outfd < 0) {

Loading…
Cancel
Save