Browse Source

fileio: imply /tmp as directory if passed as NULL to open_tmpfile_unlinkable()

We can make this smarter one day, to honour $TMPDIR and friends, but for now,
let's just use /tmp.
keep-around/964a6d9fb555cc86528eb1cc1f6d044f85584842
Lennart Poettering 6 years ago
committed by Sven Eden
parent
commit
3835ce8528
  1. 3
      src/basic/fileio.c

3
src/basic/fileio.c

@ -1264,7 +1264,8 @@ int open_tmpfile_unlinkable(const char *directory, int flags) {
char *p;
int fd;
assert(directory);
if (!directory)
directory = "/tmp";
/* Returns an unlinked temporary file that cannot be linked into the file system anymore */

Loading…
Cancel
Save