]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
networkd-ipv4acd.c: Use net/if.h for getting IFF_LOOPBACK definition
authorKhem Raj <raj.khem@gmail.com>
Tue, 8 Nov 2022 20:21:35 +0000 (12:21 -0800)
committerLuca Boccassi <luca.boccassi@gmail.com>
Wed, 9 Nov 2022 00:17:37 +0000 (01:17 +0100)
This helps in avoiding compiling errors on musl. Definition of
IFF_LOOPBACK is the reason for including linux/if_arp.h, this however
could be obtained from net/if.h glibc header equally and makes it
portable as well.

src/network/networkd-ipv4acd.c

index 4127657ebd82c805b5a28c78cd8918ee92c20d92..877dee00ec4a35f649c1c41bd9e2dd81704b838f 100644 (file)
@@ -1,6 +1,7 @@
 /* SPDX-License-Identifier: LGPL-2.1-or-later */
 
-#include <linux/if_arp.h>
+#include <net/if.h> /* IFF_LOOPBACK */
+#include <net/if_arp.h> /* ARPHRD_ETHER */
 
 #include "sd-dhcp-client.h"
 #include "sd-ipv4acd.h"