summaryrefslogtreecommitdiffstats
path: root/src/controller.c
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@rambler-co.ru>2009-03-24 18:38:11 +0300
committerVsevolod Stakhov <vsevolod@rambler-co.ru>2009-03-24 18:38:11 +0300
commit5dbf570b7df0e7c9770432884f95c14b193b5b30 (patch)
tree547448e51751b47179c46b19b9d26f2991642b30 /src/controller.c
parent616e4a7d03fba715185f55d1298cc09377313591 (diff)
downloadrspamd-5dbf570b7df0e7c9770432884f95c14b193b5b30.tar.gz
rspamd-5dbf570b7df0e7c9770432884f95c14b193b5b30.zip
* Fix many compile time warnings and polish code
Diffstat (limited to 'src/controller.c')
-rw-r--r--src/controller.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/controller.c b/src/controller.c
index 76caab0df..8a56b7f5b 100644
--- a/src/controller.c
+++ b/src/controller.c
@@ -295,7 +295,7 @@ process_command (struct controller_command *cmd, char **cmd_args, struct control
case 'r':
arg = *(cmd_args + 1);
if (!arg || *arg == '\0') {
- r = snprintf (out_buf, sizeof (out_buf), "recipient is not defined" CRLF, arg);
+ r = snprintf (out_buf, sizeof (out_buf), "recipient is not defined" CRLF);
rspamd_dispatcher_write (session->dispatcher, out_buf, r, FALSE);
return;
}
@@ -304,7 +304,7 @@ process_command (struct controller_command *cmd, char **cmd_args, struct control
case 'f':
arg = *(cmd_args + 1);
if (!arg || *arg == '\0') {
- r = snprintf (out_buf, sizeof (out_buf), "from is not defined" CRLF, arg);
+ r = snprintf (out_buf, sizeof (out_buf), "from is not defined" CRLF);
rspamd_dispatcher_write (session->dispatcher, out_buf, r, FALSE);
return;
}
@@ -314,7 +314,7 @@ process_command (struct controller_command *cmd, char **cmd_args, struct control
session->in_class = 0;
break;
default:
- r = snprintf (out_buf, sizeof (out_buf), "tokenizer is not defined" CRLF, arg);
+ r = snprintf (out_buf, sizeof (out_buf), "tokenizer is not defined" CRLF);
rspamd_dispatcher_write (session->dispatcher, out_buf, r, FALSE);
return;
}
@@ -432,6 +432,9 @@ controller_read_socket (f_str_t *in, void *arg)
session->state = STATE_REPLY;
break;
+ default:
+ msg_debug ("controller_read_socket: unknown state while reading %d", session->state);
+ break;
}
}