diff options
author | Vsevolod Stakhov <vsevolod@rambler-co.ru> | 2010-10-11 18:39:56 +0400 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@rambler-co.ru> | 2010-10-11 18:39:56 +0400 |
commit | dbee2f63ee747b5d4247038f27566bc5aebfe3b7 (patch) | |
tree | c2d60701691ab106e593be24a6974ab7dc0e6fa1 /src/controller.c | |
parent | b0ce5fefb9e694083846af1e45b09f4baa4b0446 (diff) | |
download | rspamd-dbee2f63ee747b5d4247038f27566bc5aebfe3b7.tar.gz rspamd-dbee2f63ee747b5d4247038f27566bc5aebfe3b7.zip |
Fixes bugs found with clang-static analyser.
Strictly follow c99 standart.
Turn on pedantic c99 checks.
Diffstat (limited to 'src/controller.c')
-rw-r--r-- | src/controller.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/controller.c b/src/controller.c index 9f274bc65..42c034013 100644 --- a/src/controller.c +++ b/src/controller.c @@ -258,7 +258,7 @@ process_sync_command (struct controller_session *session, gchar **args) gchar out_buf[BUFSIZ], *arg, *err_str, *symbol; gint r; guint64 rev, time; - struct statfile *st; + struct statfile *st = NULL; struct classifier_config *ccf; GList *cur; struct rspamd_binlog *binlog; @@ -591,7 +591,9 @@ process_command (struct controller_command *cmd, gchar **cmd_args, struct contro return FALSE; } } - session->learn_multiplier = strtod (arg, NULL); + else { + session->learn_multiplier = strtod (arg, NULL); + } break; default: r = rspamd_snprintf (out_buf, sizeof (out_buf), "tokenizer is not defined" CRLF); |