Blame SOURCES/mailman-2.1.29-cmd_reply_encoding.patch

f881a8
=== modified file 'Mailman/Queue/CommandRunner.py'
f881a8
--- Mailman/Queue/CommandRunner.py	2018-06-17 23:47:34 +0000
f881a8
+++ Mailman/Queue/CommandRunner.py	2021-03-31 21:53:20 +0000
f881a8
@@ -100,6 +100,11 @@
f881a8
             # E.g the outer Content-Type: was text/html
f881a8
             return
f881a8
         body = part.get_payload(decode=True)
f881a8
+        if (part.get_content_charset(None)):
f881a8
+            body = unicode(body, part.get_content_charset(),
f881a8
+                           errors='replace').encode(
f881a8
+                           Utils.GetCharSet(self.msgdata['lang']),
f881a8
+                           errors='replace')
f881a8
         # text/plain parts better have string payloads
f881a8
         assert isinstance(body, StringType) or isinstance(body, UnicodeType)
f881a8
         lines = body.splitlines()
f881a8