From f1456fa807f20bf8dd73ab3ae3312c2e8187f89f Mon Sep 17 00:00:00 2001 From: Jan Engelhardt Date: Thu, 30 Dec 2010 22:54:57 +0100 Subject: qa: resolve compiler warnings MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit -Wall flags this: make test_api test_filter make[1]: Entering directory `/home/jengelh/code/libnetfilter_conntrack/qa' CC test_api.o test_api.c:16:8: warning: return type defaults to "int" test_api.c: In function "eval_sigterm": test_api.c:23:18: warning: too many arguments for format test_api.c: In function "main": test_api.c:55:2: warning: implicit declaration of function "fork" test_api.c:34:22: warning: unused variable "h" test_api.c:102:1: warning: control reaches end of non-void function test_api.c: In function "eval_sigterm": test_api.c:29:1: warning: control reaches end of non-void function CCLD test_api CC test_filter.o test_filter.c: In function "main": test_filter.c:58:4: warning: implicit declaration of function "inet_addr" test_filter.c:74:2: warning: implicit declaration of function "strerror" test_filter.c:74:2: warning: format "%s" expects type ‘char *’, but argument 3 has type ‘int’ test_filter.c:75:1: warning: control reaches end of non-void function CCLD test_filter make[1]: Leaving directory `/home/jengelh/code/libnetfilter_conntrack/qa' Signed-off-by: Jan Engelhardt --- qa/test_filter.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'qa/test_filter.c') diff --git a/qa/test_filter.c b/qa/test_filter.c index 35fdbec..7877819 100644 --- a/qa/test_filter.c +++ b/qa/test_filter.c @@ -3,6 +3,9 @@ */ #include +#include +#include +#include #include #include @@ -23,7 +26,7 @@ static int event_cb(enum nf_conntrack_msg_type type, return NFCT_CB_CONTINUE; } -int main() +int main(void) { int i, ret; struct nfct_handle *h; @@ -72,4 +75,5 @@ int main() ret = nfct_catch(h); printf("test ret=%d (%s)\n", ret, strerror(errno)); + return EXIT_SUCCESS; } -- cgit v1.2.3