diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2020-11-23 20:07:57 +0000 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2020-11-23 20:07:57 +0000 |
commit | 08a71f0108cbd92c750924f91d3522364b30e66a (patch) | |
tree | 949cea434603adee6d1c82e2170bfb234c942020 /src/plugins/lua/spamassassin.lua | |
parent | 333733cc7ac808aff5e5ff503c32d9f3fd82afbd (diff) | |
download | rspamd-08a71f0108cbd92c750924f91d3522364b30e66a.tar.gz rspamd-08a71f0108cbd92c750924f91d3522364b30e66a.zip |
[Fix] Spamassassin: Preserve 'pcre_only' flag when dealing with regexp replacements
Diffstat (limited to 'src/plugins/lua/spamassassin.lua')
-rw-r--r-- | src/plugins/lua/spamassassin.lua | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/plugins/lua/spamassassin.lua b/src/plugins/lua/spamassassin.lua index 691930bb1..2b0e5e44e 100644 --- a/src/plugins/lua/spamassassin.lua +++ b/src/plugins/lua/spamassassin.lua @@ -1240,7 +1240,8 @@ local function post_process() lua_util.debugm(N, rspamd_config, 'replace %1 -> %2', r, nexpr) rspamd_config:replace_regexp({ old_re = rule['re'], - new_re = nre + new_re = nre, + pcre_only = is_pcre_only(rule['symbol']), }) rule['re'] = nre rule['re_expr'] = nexpr |