forked from pool/libnftnl
44 lines
1.1 KiB
Diff
44 lines
1.1 KiB
Diff
|
From 59f557d1155233ece4841d07cc1e4635fb0f5bb2 Mon Sep 17 00:00:00 2001
|
||
|
From: Jan Engelhardt <jengelh@inai.de>
|
||
|
Date: Tue, 21 Jan 2014 00:48:27 +0100
|
||
|
Subject: [PATCH 1/2] build: resolve build failure involving linux/netlink.h
|
||
|
|
||
|
This was seen with a sufficiently-old /usr/include/linux
|
||
|
(from Linux 2.6.32).
|
||
|
|
||
|
In file included from common.c:10:
|
||
|
/usr/include/linux/netlink.h:34: error: expected
|
||
|
specifier-qualifier-list before 'sa_family_t'
|
||
|
|
||
|
The solution is to include <linux/*> last of all system headers.
|
||
|
|
||
|
Signed-off-by: Jan Engelhardt <jengelh@inai.de>
|
||
|
---
|
||
|
src/common.c | 3 ++-
|
||
|
1 file changed, 2 insertions(+), 1 deletion(-)
|
||
|
|
||
|
diff --git a/src/common.c b/src/common.c
|
||
|
index b9598bf..336d2b4 100644
|
||
|
--- a/src/common.c
|
||
|
+++ b/src/common.c
|
||
|
@@ -7,6 +7,8 @@
|
||
|
* (at your option) any later version.
|
||
|
*/
|
||
|
|
||
|
+#include <stdlib.h>
|
||
|
+#include <sys/socket.h>
|
||
|
#include <linux/netlink.h>
|
||
|
#include <linux/netfilter/nfnetlink.h>
|
||
|
|
||
|
@@ -14,7 +16,6 @@
|
||
|
#include <libnftnl/common.h>
|
||
|
|
||
|
#include "internal.h"
|
||
|
-#include<stdlib.h>
|
||
|
|
||
|
struct nlmsghdr *nft_nlmsg_build_hdr(char *buf, uint16_t cmd, uint16_t family,
|
||
|
uint16_t type, uint32_t seq)
|
||
|
--
|
||
|
1.8.4
|
||
|
|