diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2016-06-23 16:07:00 +0100 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2016-06-23 16:07:00 +0100 |
commit | 0e09a5486513847905fb059185a7c5a32f50ead9 (patch) | |
tree | cc812dadbb38b3b264a106807a166f9c3bdcacd4 /src/plugins | |
parent | 8dc67975d826c02e2757ff8e3e758b1839edb044 (diff) | |
download | rspamd-0e09a5486513847905fb059185a7c5a32f50ead9.tar.gz rspamd-0e09a5486513847905fb059185a7c5a32f50ead9.zip |
[Revert] Revert flags changes in fuzzy check
Diffstat (limited to 'src/plugins')
-rw-r--r-- | src/plugins/fuzzy_check.c | 19 |
1 files changed, 1 insertions, 18 deletions
diff --git a/src/plugins/fuzzy_check.c b/src/plugins/fuzzy_check.c index a4abf3c9f..a1cf01806 100644 --- a/src/plugins/fuzzy_check.c +++ b/src/plugins/fuzzy_check.c @@ -198,12 +198,6 @@ parse_flags (struct fuzzy_rule *rule, if (elt != NULL) { map->fuzzy_flag = ucl_obj_toint (elt); - if (map->fuzzy_flag > 31) { - msg_err_config ("flags more than 31 are no longer " - "supported by rspamd"); - return; - } - elt = ucl_object_lookup (val, "max_score"); if (elt != NULL) { @@ -1525,7 +1519,6 @@ fuzzy_check_try_read (struct fuzzy_client_session *session) struct rspamd_task *task; const struct rspamd_fuzzy_reply *rep; struct rspamd_fuzzy_cmd *cmd = NULL; - guint i; gint r, ret; guchar buf[2048], *p; @@ -1547,17 +1540,7 @@ fuzzy_check_try_read (struct fuzzy_client_session *session) while ((rep = fuzzy_process_reply (&p, &r, session->commands, session->rule, &cmd)) != NULL) { if (rep->prob > 0.5) { - if (rep->flag & (1U << 31)) { - /* Multi-flag */ - for (i = 0; i < 31; i ++) { - if ((1U << i) & rep->flag) { - fuzzy_insert_result (session, rep, cmd, i + 1); - } - } - } - else { - fuzzy_insert_result (session, rep, cmd, rep->flag); - } + fuzzy_insert_result (session, rep, cmd, rep->flag); } else if (rep->value == 403) { msg_info_task ( |