From: Vsevolod Stakhov Date: Sat, 5 Mar 2016 22:20:47 +0000 (+0000) Subject: [Minor] Use utf8 length for subject X-Git-Tag: 1.2.0~112 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=eb1765564f4b0668b21f1b93a14f7eede3fcd517;p=thirdparty%2Frspamd.git [Minor] Use utf8 length for subject --- diff --git a/rules/misc.lua b/rules/misc.lua index e7d047b3fe..f3476ee810 100644 --- a/rules/misc.lua +++ b/rules/misc.lua @@ -127,7 +127,7 @@ rspamd_config.SUBJ_ALL_CAPS = { rspamd_config.LONG_SUBJ = { callback = function(task) local sbj = task:get_header('Subject') - if sbj and string.len(sbj) > 200 then + if sbj and util.strlen_utf8(sbj) > 150 then return true end return false