summaryrefslogtreecommitdiff
path: root/Mailman/MailCommandHandler.py
diff options
context:
space:
mode:
authorbwarsaw1999-04-27 22:21:28 +0000
committerbwarsaw1999-04-27 22:21:28 +0000
commitec00908d6ab6b1a8a605f4346d096758af113175 (patch)
tree5b010e8d6a54c7eef451a43114209a6cc48cf16d /Mailman/MailCommandHandler.py
parentf279e0ebef0f8bd65f3cc29314b6db8f4a1ea4f6 (diff)
downloadmailman-ec00908d6ab6b1a8a605f4346d096758af113175.tar.gz
mailman-ec00908d6ab6b1a8a605f4346d096758af113175.tar.zst
mailman-ec00908d6ab6b1a8a605f4346d096758af113175.zip
ParseMailCommands(): Two small changes. First, ignore case when
regexp matching against the confirmation line. This may have to be further extended to ignore differences in whitespace (this was all triggered by potential MS Outlook mungifications). Second, if there /was/ an error, put the whole subject line on it's own line in the error message. This'll make it easier to debug in the future.
Diffstat (limited to 'Mailman/MailCommandHandler.py')
-rw-r--r--Mailman/MailCommandHandler.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/Mailman/MailCommandHandler.py b/Mailman/MailCommandHandler.py
index 880dbf9a1..ccdb85d3a 100644
--- a/Mailman/MailCommandHandler.py
+++ b/Mailman/MailCommandHandler.py
@@ -141,13 +141,13 @@ class MailCommandHandler:
conf_pat = (r'%s -- confirmation of subscription'
r' -- request (\d{6})'
% re.escape(self.real_name))
- mo = re.search(conf_pat, subject)
+ mo = re.search(conf_pat, subject, re.IGNORECASE)
if not mo:
mo = re.search(conf_pat, msg.body)
if mo:
lines = ["confirm %s" % (mo.group(1))]
else:
- self.AddError("Subject line ignored: %s" % subject,
+ self.AddError('Subject line ignored:\n' + subject,
trunc=0)
processed = {} # For avoiding redundancies.
maxlines = mm_cfg.DEFAULT_MAIL_COMMANDS_MAX_LINES