lkml.org 
[lkml]   [2015]   [Feb]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH 37/45] include/uapi/linux/socket.h: include sys/socket.h in userspace
Date
This libc header has sockaddr definition for userspace.
Fixes compilation errors like:
error: field ‘ifru_addr’ has incomplete type
struct sockaddr ifru_addr;

Signed-off-by: Mikko Rapeli <mikko.rapeli@iki.fi>
---
include/uapi/linux/socket.h | 4 ++++
1 file changed, 4 insertions(+)

diff --git a/include/uapi/linux/socket.h b/include/uapi/linux/socket.h
index 76ab0c6..8a81197 100644
--- a/include/uapi/linux/socket.h
+++ b/include/uapi/linux/socket.h
@@ -1,6 +1,10 @@
#ifndef _UAPI_LINUX_SOCKET_H
#define _UAPI_LINUX_SOCKET_H

+#ifndef __KERNEL__
+#include <sys/socket.h>
+#endif
+
/*
* Desired design of maximum size and alignment (see RFC2553)
*/
--
2.1.4


\
 
 \ /
  Last update: 2015-02-17 00:21    [W:0.895 / U:1.572 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site