diff options
author | Vsevolod Stakhov <vsevolod@rspamd.com> | 2023-08-15 12:32:23 +0100 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@rspamd.com> | 2023-08-15 12:32:23 +0100 |
commit | 6a6536afd9c12b70c66bc9e53623eb6530b2ca73 (patch) | |
tree | 6c97014baa4be8358c388bfaef3e104ddf82955d /src/libmime | |
parent | 028a29f991f98aff5c838145e6dd6fbebd07d187 (diff) | |
download | rspamd-6a6536afd9c12b70c66bc9e53623eb6530b2ca73.tar.gz rspamd-6a6536afd9c12b70c66bc9e53623eb6530b2ca73.zip |
[Rework] Further conversion routines
Diffstat (limited to 'src/libmime')
-rw-r--r-- | src/libmime/scan_result.c | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/src/libmime/scan_result.c b/src/libmime/scan_result.c index ca17ad24b..080fc0d51 100644 --- a/src/libmime/scan_result.c +++ b/src/libmime/scan_result.c @@ -75,7 +75,6 @@ rspamd_create_metric_result(struct rspamd_task *task, const gchar *name, gint lua_sym_cbref) { struct rspamd_scan_result *metric_res; - guint i; metric_res = rspamd_mempool_alloc0(task->task_pool, sizeof(struct rspamd_scan_result)); @@ -103,14 +102,10 @@ rspamd_create_metric_result(struct rspamd_task *task, } if (task->cfg) { - struct rspamd_action *act, *tmp; - - int nact = rspamd_config_actions_size(task->cfg); + size_t nact = rspamd_config_actions_size(task->cfg); metric_res->actions_config = rspamd_mempool_alloc0(task->task_pool, sizeof(struct rspamd_action_config) * nact); - rspamd_config_actions_foreach_enumerate(task->cfg, rspamd_metric_actions_foreach_cb, metric_res); - metric_res->nactions = nact; } |