From 59e17f93bcd35d43710fa470121c66036eb7a0f3 Mon Sep 17 00:00:00 2001 From: netblue30 Date: Fri, 12 May 2017 10:37:57 -0400 Subject: compile fixes on 32bit platforms --- src/fseccomp/protocol.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src/fseccomp/protocol.c') diff --git a/src/fseccomp/protocol.c b/src/fseccomp/protocol.c index 57ce2f8e0..4a0fadb3c 100644 --- a/src/fseccomp/protocol.c +++ b/src/fseccomp/protocol.c @@ -60,6 +60,7 @@ static char *protocol[] = { NULL }; +#ifdef SYS_socket static struct sock_filter protocol_filter_command[] = { WHITELIST(AF_UNIX), WHITELIST(AF_INET), @@ -67,6 +68,7 @@ static struct sock_filter protocol_filter_command[] = { WHITELIST(AF_NETLINK), WHITELIST(AF_PACKET) }; +#endif // Note: protocol[] and protocol_filter_command are synchronized // command length @@ -75,6 +77,7 @@ struct sock_filter whitelist[] = { }; unsigned whitelist_len = sizeof(whitelist) / sizeof(struct sock_filter); +#ifdef SYS_socket static struct sock_filter *find_protocol_domain(const char *p) { int i = 0; while (protocol[i] != NULL) { @@ -85,7 +88,7 @@ static struct sock_filter *find_protocol_domain(const char *p) { return NULL; } - +#endif void protocol_print(void) { #ifndef SYS_socket -- cgit v1.2.3-70-g09d2