diff options
author | Mark Sapiro <mark@msapiro.net> | 2016-07-12 11:29:42 -0700 |
---|---|---|
committer | Mark Sapiro <mark@msapiro.net> | 2016-07-12 11:29:42 -0700 |
commit | cb51f78717fbd1f6187b61fe0b2d1e06859a3018 (patch) | |
tree | 9487502bcd1b9731b2c34a6ea9b2bab799e86eb6 /Mailman | |
parent | ba66ce7f13827b858125131fa638c87266d9cf99 (diff) | |
download | mailman2-cb51f78717fbd1f6187b61fe0b2d1e06859a3018.tar.gz mailman2-cb51f78717fbd1f6187b61fe0b2d1e06859a3018.tar.xz mailman2-cb51f78717fbd1f6187b61fe0b2d1e06859a3018.zip |
Use xmlcharrefreplace when encoding for header_filter_rules.
Diffstat (limited to 'Mailman')
-rw-r--r-- | Mailman/Handlers/SpamDetect.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Mailman/Handlers/SpamDetect.py b/Mailman/Handlers/SpamDetect.py index 1ea295a6..de19adfc 100644 --- a/Mailman/Handlers/SpamDetect.py +++ b/Mailman/Handlers/SpamDetect.py @@ -86,7 +86,7 @@ def getDecodedHeaders(msg, cset='utf-8'): # unicode it as iso-8859-1 which may result in a garbled # mess, but we have to do something. uvalue += unicode(frag, 'iso-8859-1', 'replace') - headers += '%s: %s\n' % (h, uvalue.encode(cset, 'backslashreplace')) + headers += '%s: %s\n' % (h, uvalue.encode(cset, 'xmlcharrefreplace')) return headers |