https://issues.apache.org/SpamAssassin/show_bug.cgi?id=6583
Darxus <[email protected]> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |[email protected] --- Comment #3 from Darxus <[email protected]> 2011-05-07 14:23:11 UTC --- I'm not sure if [:print:] is going to have the same locale problems as lc(), or if it'll be fine due to using whatever character set the body was encoded in. Looks like there's a simpler fix: $str =~ s/\P{IsPrint}/?/gs; >From the perlre man page: But if the "locale" or "encoding" pragmas are not used and the string is not "utf8", then "[[:xxxxx:]]" (and "\w", etc.) will not match characters 0x80-0xff; whereas "\p{IsXxxxx}" will force the string to "utf8" and can match these characters (as Unicode). [2] "\p{IsPrint}" matches characters 0x09-0x0d but "[[:print:]]" does not. -- Configure bugmail: https://issues.apache.org/SpamAssassin/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug.
