From bee121ee9b749b47da5ad3f876772c8eae7c03d3 Mon Sep 17 00:00:00 2001 From: Arturo Borrero Gonzalez Date: Fri, 4 Nov 2016 11:37:12 +0100 Subject: conntrackd: replace fprintf calls with dlog() Review fprintf() and perror() calls and replace them with proper logs, since it now supports being called anytime during runtime. While at it, several messages are fixed, deleting \n, adjusting coding style and some typos. Also, the 'conntrackd cannot start, please review your configuration' is printed before closing the log engine. Signed-off-by: Arturo Borrero Gonzalez Signed-off-by: Pablo Neira Ayuso --- src/filter.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/filter.c') diff --git a/src/filter.c b/src/filter.c index 1ae2cc5..00a5e96 100644 --- a/src/filter.c +++ b/src/filter.c @@ -138,7 +138,7 @@ static struct ct_filter *__filter_alloc(struct ct_filter *filter) if (!STATE(us_filter)) { STATE(us_filter) = ct_filter_create(); if (!STATE(us_filter)) { - fprintf(stderr, "Can't create ignore pool!\n"); + dlog(LOG_ERR, "Can't create ignore pool!"); exit(EXIT_FAILURE); } } @@ -479,7 +479,7 @@ static struct exp_filter *exp_filter_alloc(void) if (STATE(exp_filter) == NULL) { STATE(exp_filter) = exp_filter_create(); if (STATE(exp_filter) == NULL) { - fprintf(stderr, "Can't init expectation filtering!\n"); + dlog(LOG_ERR, "Can't init expectation filtering!"); return NULL; } } -- cgit v1.2.3