aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@highsecure.ru>2015-07-27 16:11:02 +0100
committerVsevolod Stakhov <vsevolod@highsecure.ru>2015-07-27 16:11:02 +0100
commita63fed5090e182256c2f8d14597c195b9f4f6a48 (patch)
tree1976c86db2e65bb433cfa3558cf15833281b0077 /src
parentaad1e3622aeea65651a7c58ce78a75603506b9c8 (diff)
downloadrspamd-a63fed5090e182256c2f8d14597c195b9f4f6a48.tar.gz
rspamd-a63fed5090e182256c2f8d14597c195b9f4f6a48.zip
Some more fixes to tokenizator init.
Diffstat (limited to 'src')
-rw-r--r--src/libstat/stat_process.c2
-rw-r--r--src/libstat/tokenizers/osb.c6
2 files changed, 6 insertions, 2 deletions
diff --git a/src/libstat/stat_process.c b/src/libstat/stat_process.c
index 141b2dfd5..1723037d2 100644
--- a/src/libstat/stat_process.c
+++ b/src/libstat/stat_process.c
@@ -167,8 +167,6 @@ rspamd_stat_get_tokenizer_runtime (struct rspamd_tokenizer_config *cf,
return NULL;
}
- tok->config = conf;
- tok->conf_len = conf_len;
tok->tokens = g_tree_new (token_node_compare_func);
rspamd_mempool_add_destructor (task->task_pool,
(rspamd_mempool_destruct_t)g_tree_destroy, tok->tokens);
diff --git a/src/libstat/tokenizers/osb.c b/src/libstat/tokenizers/osb.c
index bbb2656c2..4ba141e4f 100644
--- a/src/libstat/tokenizers/osb.c
+++ b/src/libstat/tokenizers/osb.c
@@ -140,6 +140,12 @@ rspamd_tokenizer_osb_config_from_ucl (rspamd_mempool_t * pool,
}
}
+ else {
+ elt = ucl_object_find_key (obj, "compat");
+ if (elt != NULL && ucl_object_toboolean (elt)) {
+ cf->ht = RSPAMD_OSB_HASH_COMPAT;
+ }
+ }
elt = ucl_object_find_key (obj, "window");
if (elt != NULL && ucl_object_type (elt) == UCL_INT) {