diff options
author | Andrew Lewis <nerf@judo.za.org> | 2017-03-20 06:57:04 +0200 |
---|---|---|
committer | Andrew Lewis <nerf@judo.za.org> | 2017-03-20 06:57:04 +0200 |
commit | d5c01afa57bfde74b6f566c9874e84c167275577 (patch) | |
tree | 95fcccf32215d332b06e2e1f6d9cd604af589a28 /src/rspamadm | |
parent | c38454330c20d13e8b8b1f05199c3a2545e20627 (diff) | |
download | rspamd-d5c01afa57bfde74b6f566c9874e84c167275577.tar.gz rspamd-d5c01afa57bfde74b6f566c9874e84c167275577.zip |
[Fix] Rspamadm grep: deal with unusually-formatted logs
Diffstat (limited to 'src/rspamadm')
-rw-r--r-- | src/rspamadm/grep.lua | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/rspamadm/grep.lua b/src/rspamadm/grep.lua index e49977a1d..68dc2a92c 100644 --- a/src/rspamadm/grep.lua +++ b/src/rspamadm/grep.lua @@ -45,7 +45,7 @@ return function(_, res) end else for line in h:lines() do - local hash = string.match(line, '^%d+-%d+-%d+ %d+:%d+:%d+ #%d+%(%a+%) <(%x+)>') + local hash = string.match(line, '<(%x+)>') local already_matching = false if hash then if matches[hash] then @@ -79,7 +79,7 @@ return function(_, res) matches[hash] = buffer[hash] end end - local is_end = string.match(line, '^%d+-%d+-%d+ %d+:%d+:%d+ #%d+%(%a+%) <%x+>; task; rspamd_protocol_http_reply:') + local is_end = string.match(line, '<%x+>; task; rspamd_protocol_http_reply:') if is_end then buffer[hash] = nil if matches[hash] then |