From 686d5420253bd76b1b7458f91d6ef9fc1a12b229 Mon Sep 17 00:00:00 2001 From: Adhemerval Zanella Date: Tue, 10 Oct 2023 16:22:39 -0300 Subject: posix: Sync tempname with gnulib The gnulib version contains an important change (9ce573cde), which fixes some problems with multithreading, entropy loss, and ASLR leak nfo. It also fixes an issue where getrandom is not being used on some new files generation (only for __GT_NOCREATE on first try). The 044bf893ac removed __path_search, which is now moved to another gnulib shared files (stdio-common/tmpdir.{c,h}). Tthis patch also fixes direxists to use __stat64_time64 instead of __xstat64, and move the include of pathmax.h for !_LIBC (since it is not used by glibc). The license is also changed from GPL 3.0 to 2.1, with permission from the authors (Bruno Haible and Paul Eggert). The sync also removed the clock fallback, since clock_gettime with CLOCK_REALTIME is expected to always succeed. It syncs with gnulib commit 323834962817af7b115187e8c9a833437f8d20ec. Checked on x86_64-linux-gnu. Co-authored-by: Bruno Haible Co-authored-by: Paul Eggert Reviewed-by: Bruno Haible --- libio/oldtmpfile.c | 1 + 1 file changed, 1 insertion(+) (limited to 'libio') diff --git a/libio/oldtmpfile.c b/libio/oldtmpfile.c index af467a6..f09ee06 100644 --- a/libio/oldtmpfile.c +++ b/libio/oldtmpfile.c @@ -22,6 +22,7 @@ #include #include #include +#include /* This returns a new stream opened on a temporary file (generated by tmpnam). The file is opened with mode "w+b" (binary read/write). -- cgit v1.1