From 3052311a6d7a2b14d2ff24edff6344cf1ae109b4 Mon Sep 17 00:00:00 2001 From: Wilfried Goesgens Date: Sat, 23 Jan 2016 15:30:39 +0100 Subject: [PATCH] Silence logging in non-debug usecases. The raspii users gonna love this. --- citadel/citserver.c | 63 ------------- citadel/database.c | 2 +- citadel/modules/ctdlproto/serv_ctdlproto.c | 81 +++++++++++++++++ citadel/modules/ctdlproto/serv_file.c | 88 ++++++++++--------- citadel/modules/ctdlproto/serv_rooms.c | 34 +++---- citadel/modules/extnotify/extnotify_main.c | 18 ++-- citadel/modules/network/serv_netspool.c | 6 +- citadel/modules/network/serv_network.c | 4 +- .../networkclient/serv_networkclient.c | 2 +- citadel/modules/smtp/serv_smtpqueue.c | 10 ++- citadel/modules/xmpp/xmpp_queue.c | 2 +- citadel/msgbase.c | 2 +- citadel/room_ops.c | 6 +- citadel/serv_extensions.c | 15 +++- citadel/serv_extensions.h | 23 +++++ 15 files changed, 209 insertions(+), 147 deletions(-) create mode 100644 citadel/modules/ctdlproto/serv_ctdlproto.c diff --git a/citadel/citserver.c b/citadel/citserver.c index 9832b7812..9f41f35f5 100644 --- a/citadel/citserver.c +++ b/citadel/citserver.c @@ -373,69 +373,6 @@ void citproto_begin_admin_session() { } - - -/* - * This loop recognizes all server commands. - */ -void do_command_loop(void) { - char cmdbuf[SIZ]; - - time(&CC->lastcmd); - memset(cmdbuf, 0, sizeof cmdbuf); /* Clear it, just in case */ - if (client_getln(cmdbuf, sizeof cmdbuf) < 1) { - syslog(LOG_ERR, "Citadel client disconnected: ending session.\n"); - CC->kill_me = KILLME_CLIENT_DISCONNECTED; - return; - } - - /* Log the server command, but don't show passwords... */ - if ( (strncasecmp(cmdbuf, "PASS", 4)) && (strncasecmp(cmdbuf, "SETP", 4)) ) { - syslog(LOG_INFO, "[%d][%s(%ld)] %s", - CC->cs_pid, CC->curr_user, CC->user.usernum, cmdbuf - ); - } - else { - syslog(LOG_INFO, "[%d][%s(%ld)]