Patchwork [net-next,v2,07/10] headers, tipc: Add missing #include to <linux/tipc_config.h> for userland

login
register
mail settings
Submitter Ben Hutchings
Date Aug. 25, 2011, 4:45 a.m.
Message ID <1314247515.27179.124.camel@deadeye>
Download mbox | patch
Permalink /patch/111447/
State Accepted
Delegated to: David Miller
Headers show

Comments

Ben Hutchings - Aug. 25, 2011, 4:45 a.m.
<linux/tipc_config.h> defines inline functions using ntohs() etc.
For userland these are defined in <arpa/inet.h>.

Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
---
 include/linux/tipc_config.h |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)

Patch

diff --git a/include/linux/tipc_config.h b/include/linux/tipc_config.h
index 0db2395..9730b0e 100644
--- a/include/linux/tipc_config.h
+++ b/include/linux/tipc_config.h
@@ -41,6 +41,10 @@ 
 #include <linux/string.h>
 #include <asm/byteorder.h>
 
+#ifndef __KERNEL__
+#include <arpa/inet.h> /* for ntohs etc. */
+#endif
+
 /*
  * Configuration
  *