diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2015-11-20 16:33:34 +0000 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2015-11-20 16:33:34 +0000 |
commit | c3896936f524bd19d732b5034c87058260bd04e6 (patch) | |
tree | 1518d2aef66c4ffe6e171b596d15e9c94d2194d0 /test/rspamd_test_suite.c | |
parent | 13cb93001a2cb7dbf7db85b25ac22558da4f610b (diff) | |
download | rspamd-c3896936f524bd19d732b5034c87058260bd04e6.tar.gz rspamd-c3896936f524bd19d732b5034c87058260bd04e6.zip |
Fix tests
Diffstat (limited to 'test/rspamd_test_suite.c')
-rw-r--r-- | test/rspamd_test_suite.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/test/rspamd_test_suite.c b/test/rspamd_test_suite.c index 97d0565b8..4ba11ea0f 100644 --- a/test/rspamd_test_suite.c +++ b/test/rspamd_test_suite.c @@ -16,10 +16,8 @@ main (int argc, char **argv) rspamd_main = (struct rspamd_main *)g_malloc (sizeof (struct rspamd_main)); memset (rspamd_main, 0, sizeof (struct rspamd_main)); rspamd_main->server_pool = rspamd_mempool_new (rspamd_mempool_suggest_size (), NULL); - rspamd_main->cfg = (struct rspamd_config *)g_malloc (sizeof (struct rspamd_config)); - cfg = rspamd_main->cfg; - memset (cfg, 0, sizeof (struct rspamd_config)); - rspamd_init_cfg (cfg, FALSE); + cfg = rspamd_config_new (); + rspamd_main->cfg = cfg; cfg->cfg_pool = rspamd_mempool_new (rspamd_mempool_suggest_size (), NULL); cfg->log_type = RSPAMD_LOG_CONSOLE; cfg->log_level = G_LOG_LEVEL_INFO; @@ -29,7 +27,7 @@ main (int argc, char **argv) g_test_init (&argc, &argv, NULL); - rspamd_init_libs (); + cfg->libs_ctx = rspamd_init_libs (); rspamd_stat_init (cfg); base = event_init (); |