aboutsummaryrefslogtreecommitdiffstats
path: root/src/libserver/protocol.c
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@highsecure.ru>2015-08-25 18:14:36 +0100
committerVsevolod Stakhov <vsevolod@highsecure.ru>2015-08-25 18:14:36 +0100
commit09e125bdc94c80b0582155d45b055fa84627e20d (patch)
treefac0db24c254d50fa46cac819bd07e005c01e03e /src/libserver/protocol.c
parent2edb82c0e02cab3f2111ac5a8d792c2eeeb18642 (diff)
downloadrspamd-09e125bdc94c80b0582155d45b055fa84627e20d.tar.gz
rspamd-09e125bdc94c80b0582155d45b055fa84627e20d.zip
Fix settings for actions other than reject
Diffstat (limited to 'src/libserver/protocol.c')
-rw-r--r--src/libserver/protocol.c10
1 files changed, 2 insertions, 8 deletions
diff --git a/src/libserver/protocol.c b/src/libserver/protocol.c
index 162f75f40..3ee2def4d 100644
--- a/src/libserver/protocol.c
+++ b/src/libserver/protocol.c
@@ -866,15 +866,9 @@ rspamd_metric_result_ucl (struct rspamd_task *task,
gchar action_char;
m = mres->metric;
+ mres->action = rspamd_check_action_metric (task, mres->score,
+ &required_score, m);
- /* XXX: handle settings */
- if (mres->action == METRIC_ACTION_MAX) {
- mres->action = rspamd_check_action_metric (task, mres->score,
- &required_score, m);
- }
- else {
- required_score = mres->metric->actions[mres->action].score;
- }
action = mres->action;
is_spam = (action == METRIC_ACTION_REJECT);