From c73988300f943e185a50aaba015f2f114ffcb262 Mon Sep 17 00:00:00 2001 From: Gurchetan Singh Date: Thu, 8 Aug 2019 09:42:07 -0700 Subject: [PATCH] util: added missing headers in anon-file MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Otherwise I get: ../src/util/anon_file.c: In function ‘create_tmpfile_cloexec’: ../src/util/anon_file.c:75:9: error: implicit declaration of function ‘mkostemp’ [-Werror=implicit-function-declaration] fd = mkostemp(tmpname, O_CLOEXEC); ^~~~~~~~ ../src/util/anon_file.c:133:7: error: implicit declaration of function ‘asprintf’ [-Werror=implicit-function-declaration] asprintf(&name, "%s/mesa-shared-%s-XXXXXX", path, debug_name); ^~~~~~~~ ../src/util/anon_file.c:141:4: error: implicit declaration of function ‘free’ [-Werror=implicit-function-declaration] free(name) Fixes: c0376a ("util: add anon_file.h for all memfd/temp file usage") --- src/util/anon_file.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/util/anon_file.c b/src/util/anon_file.c index 2780c74a680..90c55cd5af0 100644 --- a/src/util/anon_file.c +++ b/src/util/anon_file.c @@ -33,6 +33,8 @@ #include #include #include +#include +#include #ifdef __FreeBSD__ #include -- 2.30.2