]> git.ipfire.org Git - thirdparty/systemd.git/blobdiff - src/basic/memfd-util.c
build-sys: use #if Y instead of #ifdef Y everywhere
[thirdparty/systemd.git] / src / basic / memfd-util.c
index 9d638b27f086df9ac9295458df0d06594bd77ec2..8f4f0e3a24803bc63361c50f9dafc4e2cae1ff96 100644 (file)
@@ -1,5 +1,3 @@
-/*-*- Mode: C; c-basic-offset: 8; indent-tabs-mode: nil -*-*/
-
 /***
   This file is part of systemd.
 
   along with systemd; If not, see <http://www.gnu.org/licenses/>.
 ***/
 
+#include <errno.h>
 #include <fcntl.h>
-#ifdef HAVE_LINUX_MEMFD_H
+#include <sys/stat.h>
+#include <unistd.h>
+#if HAVE_LINUX_MEMFD_H
 #include <linux/memfd.h>
 #endif
 #include <stdio.h>
 #include <sys/mman.h>
 #include <sys/prctl.h>
 
+#include "alloc-util.h"
 #include "fd-util.h"
+#include "macro.h"
 #include "memfd-util.h"
 #include "missing.h"
 #include "string-util.h"
 #include "utf8.h"
-#include "util.h"
 
 int memfd_new(const char *name) {
         _cleanup_free_ char *g = NULL;