diff options
author | Matthias Schiffer <mschiffer@universe-factory.net> | 2013-08-27 17:57:06 +0200 |
---|---|---|
committer | Matthias Schiffer <mschiffer@universe-factory.net> | 2013-08-27 17:57:06 +0200 |
commit | 81bff2df037a218cb973559a2bfbfbd259b1cbad (patch) | |
tree | baeeeb599991e6de736e91f3b9e80f8603fd7bb0 /src/fastd.c | |
parent | e91f17de87175d822ae7e3d3238e7a0021a645ad (diff) | |
download | fastd-81bff2df037a218cb973559a2bfbfbd259b1cbad.tar fastd-81bff2df037a218cb973559a2bfbfbd259b1cbad.zip |
Introduce new log level debug2 for potentially very frequent messages
Diffstat (limited to 'src/fastd.c')
-rw-r--r-- | src/fastd.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/fastd.c b/src/fastd.c index 0da1c08..65fc59f 100644 --- a/src/fastd.c +++ b/src/fastd.c @@ -36,6 +36,7 @@ #include <pthread.h> #include <signal.h> #include <string.h> +#include <syslog.h> #include <sys/resource.h> @@ -107,7 +108,7 @@ static void init_log(fastd_context_t *ctx) { pr_debug_errno(ctx, "seteuid"); } - if (ctx->conf->log_syslog_level >= 0) + if (ctx->conf->log_syslog_level > LL_UNSPEC) openlog(ctx->conf->log_syslog_ident, LOG_PID, LOG_DAEMON); fastd_log_file_t *config; @@ -452,7 +453,7 @@ static void handle_tasks(fastd_context_t *ctx) { break; case TASK_KEEPALIVE: - pr_debug(ctx, "sending keepalive to %P", task->peer); + pr_debug2(ctx, "sending keepalive to %P", task->peer); ctx->conf->protocol->send(ctx, task->peer, fastd_buffer_alloc(ctx, 0, ctx->conf->min_encrypt_head_space, ctx->conf->min_encrypt_tail_space)); break; |