From 4d7e6d4f7880eac1e7848e2591aa95420c60e3ba Mon Sep 17 00:00:00 2001 From: Johan Askerin Date: Fri, 12 Feb 2016 15:17:25 +0100 Subject: [PATCH] In tempfile(): O_DIRECTORY is dependent on $ARCH, don't hardcore O_TMPFILE Signed-off-by: Johan Askerin --- tempfile.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tempfile.c b/tempfile.c index 7acc2d0..9875b18 100644 --- a/tempfile.c +++ b/tempfile.c @@ -24,7 +24,8 @@ #ifndef O_TMPFILE /* Too old GLIBC or kernel */ #warning O_TMPFILE missing on your system, tempfile() may not work! -#define O_TMPFILE 020200000 /* Define and let it fail at runtime */ +#define __O_TMPFILE 020000000 +#define O_TMPFILE (__O_TMPFILE | O_DIRECTORY) /* Define and let it fail at runtime */ #endif /**