diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2017-02-09 17:25:24 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-02-09 17:25:24 +0000 |
commit | f09750119bc4f04a78c713a720077f64e2923dde (patch) | |
tree | 3acf39038c80ca001bb24525ff01c8a82e105cb1 | |
parent | 26a1aef7d9b6559a30a94e369854ceb914c81141 (diff) | |
parent | 4614fba9ef02f79fef40ce82bab3cb8fabb1eefd (diff) | |
download | rspamd-f09750119bc4f04a78c713a720077f64e2923dde.tar.gz rspamd-f09750119bc4f04a78c713a720077f64e2923dde.zip |
Merge pull request #1407 from fatalbanana/max
Multimap: don't try handle gaps in Received headers
-rw-r--r-- | src/plugins/lua/multimap.lua | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/src/plugins/lua/multimap.lua b/src/plugins/lua/multimap.lua index a5152a458..519c64b22 100644 --- a/src/plugins/lua/multimap.lua +++ b/src/plugins/lua/multimap.lua @@ -712,14 +712,8 @@ local function multimap_callback(task, rule) received = function() local hdrs = task:get_received_headers() if hdrs and hdrs[1] then - local num_hdrs = 0 - for i in ipairs(hdrs) do - if i > num_hdrs then - num_hdrs = i - end - end for pos, h in ipairs(hdrs) do - match_received_header(rule, pos, num_hdrs, h) + match_received_header(rule, pos, #hdrs, h) end end end, |