diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2016-01-13 20:08:49 +0000 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2016-01-13 20:08:49 +0000 |
commit | defcd82bfd954693cdcd1767227bfcf04e63ff59 (patch) | |
tree | 2487d969dc27cf43bf3e1dac7c19e1a885a68a95 /src/libstat | |
parent | a2706116f96b82ce9bbf86b252babb8b5c98a3e9 (diff) | |
download | rspamd-defcd82bfd954693cdcd1767227bfcf04e63ff59.tar.gz rspamd-defcd82bfd954693cdcd1767227bfcf04e63ff59.zip |
Do not treat bad backend as an assert
Diffstat (limited to 'src/libstat')
-rw-r--r-- | src/libstat/stat_config.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/libstat/stat_config.c b/src/libstat/stat_config.c index 5e1a8672b..0a19f0554 100644 --- a/src/libstat/stat_config.c +++ b/src/libstat/stat_config.c @@ -130,7 +130,13 @@ rspamd_stat_init (struct rspamd_config *cfg, struct event_base *ev_base) while (cur) { clf = cur->data; bk = rspamd_stat_get_backend (clf->backend); - g_assert (bk != NULL); + + if (bk == NULL) { + msg_err_config ("cannot get backend of type %s, so disable classifier" + " completely", clf->backend, clf->name); + cur = g_list_next (cur); + continue; + } /* XXX: * Here we get the first classifier tokenizer config as the only one |