]> git.ipfire.org Git - thirdparty/lxc.git/commitdiff
cmds: fix includes
authorChristian Brauner <christian.brauner@ubuntu.com>
Mon, 27 Sep 2021 10:09:17 +0000 (12:09 +0200)
committerChristian Brauner <christian.brauner@ubuntu.com>
Mon, 27 Sep 2021 10:09:17 +0000 (12:09 +0200)
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
src/lxc/cmd/lxc_init.c
src/lxc/cmd/lxc_monitord.c
src/lxc/cmd/lxc_user_nic.c
src/lxc/cmd/lxc_usernsexec.c

index 6491e2406074e134afa26115f811b248f4fec3e3..e21e726545a07ef731e0267ed75132e14518d2d0 100644 (file)
@@ -1,8 +1,7 @@
 /* SPDX-License-Identifier: LGPL-2.1+ */
 
-#ifndef _GNU_SOURCE
-#define _GNU_SOURCE 1
-#endif
+#include "config.h"
+
 #include <ctype.h>
 #include <errno.h>
 #include <fcntl.h>
@@ -20,7 +19,6 @@
 #include "version.h"
 
 #include "compiler.h"
-#include "config.h"
 #include "initutils.h"
 #include "memory_utils.h"
 #include "parse.h"
index d477e9ade87b664ca4a16b1b0a224543dfaf920c..a194fbea80d8a83dea1da2caa9008ea726e725dd 100644 (file)
@@ -1,8 +1,7 @@
 /* SPDX-License-Identifier: LGPL-2.1+ */
 
-#ifndef _GNU_SOURCE
-#define _GNU_SOURCE 1
-#endif
+#include "config.h"
+
 #include <errno.h>
 #include <fcntl.h>
 #include <net/if.h>
@@ -24,7 +23,6 @@
 #include "lxc.h"
 
 #include "af_unix.h"
-#include "config.h"
 #include "log.h"
 #include "mainloop.h"
 #include "monitor.h"
index 7d861f4afeba5899c9df2b70f85c67973b01ca3c..83e79cd1ed93c612b9aacc9c4168e4083a17c533 100644 (file)
@@ -1,8 +1,7 @@
 /* SPDX-License-Identifier: LGPL-2.1+ */
 
-#ifndef _GNU_SOURCE
-#define _GNU_SOURCE 1
-#endif
+#include "config.h"
+
 #include <arpa/inet.h>
 #include <ctype.h>
 #include <errno.h>
@@ -30,7 +29,6 @@
 #include <unistd.h>
 
 #include "compiler.h"
-#include "config.h"
 #include "file_utils.h"
 #include "log.h"
 #include "memory_utils.h"
@@ -42,7 +40,7 @@
 #include "syscall_wrappers.h"
 #include "utils.h"
 
-#ifndef HAVE_STRLCPY
+#if !HAVE_STRLCPY
 #include "strlcpy.h"
 #endif
 
index 9ac33e7414f95704c4f9be57f9fdf7833e8b5aa1..96a1182a3037d949815b107b7a277aa84fd202c8 100644 (file)
@@ -1,8 +1,7 @@
 /* SPDX-License-Identifier: LGPL-2.1+ */
 
-#ifndef _GNU_SOURCE
-#define _GNU_SOURCE 1
-#endif
+#include "config.h"
+
 #include <errno.h>
 #include <fcntl.h>
 #include <grp.h>
@@ -22,7 +21,6 @@
 
 #include "compiler.h"
 #include "conf.h"
-#include "config.h"
 #include "hlist.h"
 #include "list.h"
 #include "log.h"