aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@highsecure.ru>2013-11-16 22:10:29 +0000
committerVsevolod Stakhov <vsevolod@highsecure.ru>2013-11-16 22:10:29 +0000
commit52d421b375e5193cf091c2e1329d99a4a80d40c3 (patch)
treea40baeaba2c01ff1053caf1965ab23412ab6cef8 /src/plugins
parente175d9762f84e52c1fae2fca59a12dbbc142034f (diff)
downloadrspamd-52d421b375e5193cf091c2e1329d99a4a80d40c3.tar.gz
rspamd-52d421b375e5193cf091c2e1329d99a4a80d40c3.zip
Use min_bytes setting in fuzzy_check for normal parts.
Diffstat (limited to 'src/plugins')
-rw-r--r--src/plugins/fuzzy_check.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/plugins/fuzzy_check.c b/src/plugins/fuzzy_check.c
index 066d58272..de3fdb57b 100644
--- a/src/plugins/fuzzy_check.c
+++ b/src/plugins/fuzzy_check.c
@@ -718,6 +718,13 @@ fuzzy_symbol_callback (struct worker_task *task, void *unused)
continue;
}
+ /* Check length of part */
+ if (fuzzy_module_ctx->min_bytes > part->content->len) {
+ msg_info ("<%s>, part is shorter than %d symbols, skip fuzzy check",
+ task->message_id, fuzzy_module_ctx->min_bytes);
+ cur = g_list_next (cur);
+ continue;
+ }
/* Check length of hash */
hashlen = strlen (part->fuzzy->hash_pipe);
if (hashlen == 0) {