73 lines
2.4 KiB
Diff
73 lines
2.4 KiB
Diff
|
diff --git a/Make_global.am b/Make_global.am
|
||
|
index 3ff531f..2eeb886 100644
|
||
|
--- a/Make_global.am
|
||
|
+++ b/Make_global.am
|
||
|
@@ -1,6 +1,5 @@
|
||
|
INCLUDES=$(all_includes) -I$(top_srcdir)/include
|
||
|
|
||
|
AM_CFLAGS = -std=gnu99 -W -Wall \
|
||
|
- -Werror \
|
||
|
-Wmissing-prototypes -Wwrite-strings -Wcast-qual -Wfloat-equal -Wshadow -Wpointer-arith -Wbad-function-cast -Wsign-compare -Waggregate-return -Wmissing-declarations -Wredundant-decls -Wnested-externs -Winline -Wstrict-prototypes -Wundef \
|
||
|
-Wno-unused-parameter
|
||
|
diff --git a/src/Makefile.am b/src/Makefile.am
|
||
|
index 494da4f..2d8c6b6 100644
|
||
|
--- a/src/Makefile.am
|
||
|
+++ b/src/Makefile.am
|
||
|
@@ -1,8 +1,6 @@
|
||
|
include $(top_srcdir)/Make_global.am
|
||
|
|
||
|
-YACC=@YACC@ -d
|
||
|
-
|
||
|
-CLEANFILES = read_config_yy.c read_config_lex.c
|
||
|
+AM_YFLAGS = -d
|
||
|
|
||
|
sbin_PROGRAMS = conntrack conntrackd
|
||
|
|
||
|
@@ -22,9 +20,6 @@ conntrackd_SOURCES = alarm.c main.c run.c hash.c queue.c rbtree.c \
|
||
|
build.c parse.c \
|
||
|
read_config_yy.y read_config_lex.l
|
||
|
|
||
|
-# yacc and lex generate dirty code
|
||
|
-read_config_yy.o read_config_lex.o: AM_CFLAGS += -Wno-missing-prototypes -Wno-missing-declarations -Wno-implicit-function-declaration -Wno-nested-externs -Wno-undef -Wno-redundant-decls
|
||
|
|
||
|
conntrackd_LDFLAGS = $(all_libraries) @LIBNETFILTER_CONNTRACK_LIBS@
|
||
|
|
||
|
-EXTRA_DIST = read_config_yy.h
|
||
|
diff --git a/src/conntrack.c b/src/conntrack.c
|
||
|
index 82ff544..23050a4 100644
|
||
|
--- a/src/conntrack.c
|
||
|
+++ b/src/conntrack.c
|
||
|
@@ -299,7 +299,7 @@ err2str(int err, enum action command)
|
||
|
{ CT_CREATE, ETIME, "conntrack has expired" },
|
||
|
{ EXP_CREATE, ENOENT, "master conntrack not found" },
|
||
|
{ EXP_CREATE, EINVAL, "invalid parameters" },
|
||
|
- { ~0UL, EPERM, "sorry, you must be root or get "
|
||
|
+ { (enum action) ~0UL, EPERM, "sorry, you must be root or get "
|
||
|
"CAP_NET_ADMIN capability to do this"}
|
||
|
};
|
||
|
|
||
|
diff --git a/src/ignore_pool.c b/src/ignore_pool.c
|
||
|
index 027d628..2f951e8 100644
|
||
|
--- a/src/ignore_pool.c
|
||
|
+++ b/src/ignore_pool.c
|
||
|
@@ -25,6 +25,7 @@
|
||
|
#include <libnetfilter_conntrack/libnetfilter_conntrack.h>
|
||
|
#include <stdlib.h>
|
||
|
#include <string.h>
|
||
|
+#include <limits.h>
|
||
|
|
||
|
/* XXX: These should be configurable, better use a rb-tree */
|
||
|
#define IGNORE_POOL_SIZE 128
|
||
|
diff --git a/src/main.c b/src/main.c
|
||
|
index 2e1ccd8..084643c 100644
|
||
|
--- a/src/main.c
|
||
|
+++ b/src/main.c
|
||
|
@@ -26,6 +26,7 @@
|
||
|
#include <string.h>
|
||
|
#include <stdlib.h>
|
||
|
#include <unistd.h>
|
||
|
+#include <limits.h>
|
||
|
|
||
|
struct ct_general_state st;
|
||
|
union ct_state state;
|