Skip to contentSkip to conversation

netfilter: Move linux/in.h and linux/in6.h inclusions outside of #ifdef __KERNEL__

PATCH Applied Matt Kraai 2 participants 2 messages Jul 31, 2008 – Aug 1, 2008 netfilter

lore
Share & tools
lore

Matt Kraai

author
#0 lore raw

PATCH 1/1 netfilter: Move linux/in.h and linux/in6.h inclusions outside of #ifdef __KERNEL__

From: Matt Kraai <[email protected]>

netfilter.h can't be used in userspace without including linux/in.h and linux/in6.h first. netfilter.h includes its own linux/in.h and linux/in6.h include statements, these are stripped by make headers-install because they are inside #ifdef __KERNEL__ however. Move them out to fix this.

---

The original report of this bug is at
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=487103.

This patch applies to the latest linux-2.6 tree.

include/linux/netfilter.h +2 -2
index 0c5eb7e..6060e56 100644
@@ -7,13 +7,13 @@
 #include <linux/net.h>
 #include <linux/netdevice.h>
 #include <linux/if.h>
-#include <linux/in.h>
-#include <linux/in6.h>
 #include <linux/wait.h>
 #include <linux/list.h>
 #include <net/net_namespace.h>
 #endif
 #include <linux/types.h>
+#include <linux/in.h>
+#include <linux/in6.h>
 #include <linux/compiler.h>
 
 /* Responses from hook functions. */
#1 lore raw
Quoted 7 lines · Matt Kraai

From: Matt Kraai <[email protected]>

netfilter.h can't be used in userspace without including linux/in.h and linux/in6.h first. netfilter.h includes its own linux/in.h and linux/in6.h include statements, these are stripped by make headers-install because they are inside #ifdef __KERNEL__ however. Move them out to fix this.

Applied, thanks.