]> source.dussan.org Git - rspamd.git/commitdiff
* Incorrectly removed in previous commit
authorVsevolod Stakhov <vsevolod@rambler-co.ru>
Thu, 17 Jun 2010 12:54:28 +0000 (16:54 +0400)
committerVsevolod Stakhov <vsevolod@rambler-co.ru>
Thu, 17 Jun 2010 12:54:28 +0000 (16:54 +0400)
src/filter.c
src/plugins/chartable.c

index 809d4b3269c496209753bb0fd81c7673674b7151..b2c4b7ab567880f5b061918ab2ec75ea9f7e16b2 100644 (file)
@@ -60,6 +60,7 @@ insert_metric_result (struct worker_task *task, struct metric *metric, const cha
                memory_pool_add_destructor (task->task_pool, (pool_destruct_func) g_hash_table_destroy, metric_res->symbols);
                metric_res->metric = metric;
                metric_res->grow_factor = 0;
+               metric_res->score = 0;
                g_hash_table_insert (task->results, (gpointer) metric->name, metric_res);
        }
        
index 347fa5cab452e3450c04403f5f55339995a93da5..e5b5893fb5c8cdf18a7a65ab1ca3b6d85320d435 100644 (file)
@@ -75,6 +75,12 @@ chartable_module_config (struct config_file *cfg)
        char                           *value;
        int                             res = TRUE;
 
+       if ((value = get_module_opt (cfg, "chartable", "symbol")) != NULL) {
+               chartable_module_ctx->symbol = memory_pool_strdup (chartable_module_ctx->chartable_pool, value);
+       }
+       else {
+               chartable_module_ctx->symbol = DEFAULT_SYMBOL;
+       } 
        if ((value = get_module_opt (cfg, "chartable", "threshold")) != NULL) {
                errno = 0;
                chartable_module_ctx->threshold = strtod (value, NULL);