From: Vsevolod Stakhov Date: Thu, 23 Jul 2009 16:22:00 +0000 (+0400) Subject: * Fix some more bugs X-Git-Tag: 0.2.7~73 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=be7df664847ca44eb41056d36095eb75f9c50bcd;p=rspamd.git * Fix some more bugs --- diff --git a/src/cfg_file.h b/src/cfg_file.h index d93bc9d34..44e9421b0 100644 --- a/src/cfg_file.h +++ b/src/cfg_file.h @@ -10,7 +10,6 @@ #include "mem_pool.h" #include "upstream.h" #include "memcached.h" -#include "filter.h" #define DEFAULT_BIND_PORT 768 #define DEFAULT_CONTROL_PORT 7608 diff --git a/src/cfg_utils.c b/src/cfg_utils.c index 30318ffda..6b095e6d8 100644 --- a/src/cfg_utils.c +++ b/src/cfg_utils.c @@ -413,6 +413,7 @@ parse_filters_str (struct config_file *cfg, const char *str) cur = NULL; /* Search modules from known C modules */ for (i = 0; i < MODULES_NUM; i++) { + g_strstrip (*p); if (strcasecmp (modules[i].name, *p) == 0) { cur = memory_pool_alloc (cfg->cfg_pool, sizeof (struct filter)); cur->type = C_FILTER; diff --git a/src/main.c b/src/main.c index 2ff31ecfc..00cf68203 100644 --- a/src/main.c +++ b/src/main.c @@ -543,7 +543,7 @@ main (int argc, char **argv, char **env) while (l) { filt = l->data; if (filt->module) { - if (filt->module->module_config_func (cfg)) { + if (!filt->module->module_config_func (cfg)) { res = FALSE; } } @@ -655,7 +655,7 @@ main (int argc, char **argv, char **env) while (l) { filt = l->data; if (filt->module) { - if (filt->module->module_config_func (cfg)) { + if (!filt->module->module_config_func (cfg)) { res = FALSE; } }