summaryrefslogtreecommitdiff
path: root/src/mailman/runners/command.py
diff options
context:
space:
mode:
authortoshio2012-03-14 06:30:23 +0000
committertoshio2012-03-14 06:30:23 +0000
commitb948dfac6899733f963bc9da2ceb06711c2d1e91 (patch)
treef66a340c1ad756dcd575753baf4dd06eb1e7d1e4 /src/mailman/runners/command.py
parentd1a9979ecf35d05ed115651dcc6b8680af08b954 (diff)
parenteb509dc0466f34f63ab6dcf159de2f9137cb3fdb (diff)
downloadmailman-b948dfac6899733f963bc9da2ceb06711c2d1e91.tar.gz
mailman-b948dfac6899733f963bc9da2ceb06711c2d1e91.tar.zst
mailman-b948dfac6899733f963bc9da2ceb06711c2d1e91.zip
Python-2.6 compat fixes
Diffstat (limited to 'src/mailman/runners/command.py')
-rw-r--r--src/mailman/runners/command.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/mailman/runners/command.py b/src/mailman/runners/command.py
index f13b02229..ac611ed3a 100644
--- a/src/mailman/runners/command.py
+++ b/src/mailman/runners/command.py
@@ -85,7 +85,7 @@ class CommandFinder:
# bogus characters. Otherwise, there's nothing in the subject
# that we can use.
if isinstance(raw_subject, unicode):
- safe_subject = raw_subject.encode('us-ascii', errors='ignore')
+ safe_subject = raw_subject.encode('us-ascii', 'ignore')
self.command_lines.append(safe_subject)
# Find the first text/plain part of the message.
part = None
@@ -119,7 +119,7 @@ class CommandFinder:
# ASCII commands and arguments, ignore anything else.
parts = [(part
if isinstance(part, unicode)
- else part.decode('ascii', errors='ignore'))
+ else part.decode('ascii', 'ignore'))
for part in parts]
yield parts
@@ -139,7 +139,7 @@ The results of your email command are provided below.
def write(self, text):
if not isinstance(text, unicode):
- text = text.decode(self.charset, errors='ignore')
+ text = text.decode(self.charset, 'ignore')
self._output.write(text)
def __unicode__(self):