Commit a2f654ef authored by Kevin Wolf's avatar Kevin Wolf

libc: mkstemp() sollte O_RDWR benutzen

! libc: Schreibgeschützte temporäre Dateien sind doof
Signed-off-by: Kevin Wolf's avatarKevin Wolf <kevin@tyndur.org>
parent e1968631
......@@ -102,7 +102,7 @@ int mkstemp(char* template)
return fd;
}
fd = open(buf, O_EXCL | O_CREAT);
fd = open(buf, O_EXCL | O_CREAT | O_RDWR);
} while (fd == -1 && (errno == EEXIST || errno == EINTR));
strcpy(template, buf);
......
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