aboutsummaryrefslogtreecommitdiffstats
path: root/Mailman/Cgi/confirm.py
diff options
context:
space:
mode:
authorMark Sapiro <msapiro@value.net>2011-02-07 12:42:05 -0800
committerMark Sapiro <msapiro@value.net>2011-02-07 12:42:05 -0800
commit2858a6747610370e07f2e4dd0e8d76c28ba0c779 (patch)
tree522425758f3269374ce32c4697b64700a369b2ac /Mailman/Cgi/confirm.py
parent12f54c4b4f27ed1514f770f062bcc9c5b239dd71 (diff)
downloadmailman2-2858a6747610370e07f2e4dd0e8d76c28ba0c779.tar.gz
mailman2-2858a6747610370e07f2e4dd0e8d76c28ba0c779.tar.xz
mailman2-2858a6747610370e07f2e4dd0e8d76c28ba0c779.zip
- Fixed an uncaught KeyError when poster tries to cancel a post which was
already handled. Bug #266224.
Diffstat (limited to '')
-rw-r--r--Mailman/Cgi/confirm.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/Mailman/Cgi/confirm.py b/Mailman/Cgi/confirm.py
index 8c681732..6ad0ffae 100644
--- a/Mailman/Cgi/confirm.py
+++ b/Mailman/Cgi/confirm.py
@@ -1,4 +1,4 @@
-# Copyright (C) 2001-2010 by the Free Software Foundation, Inc.
+# Copyright (C) 2001-2011 by the Free Software Foundation, Inc.
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
@@ -634,6 +634,7 @@ def heldmsg_confirm(mlist, doc, cookie):
try:
# Do this in two steps so we can get the preferred language for
# the user who posted the message.
+ subject = 'n/a'
op, id = mlist.pend_confirm(cookie)
ign, sender, msgsubject, ign, ign, ign = mlist.GetRecord(id)
lang = mlist.getMemberLanguage(sender)
@@ -644,7 +645,7 @@ def heldmsg_confirm(mlist, doc, cookie):
# Discard the message
mlist.HandleRequest(id, mm_cfg.DISCARD,
_('Sender discarded message via web.'))
- except Errors.LostHeldMessage:
+ except (Errors.LostHeldMessage, KeyError):
bad_confirmation(doc, _('''The held message with the Subject:
header <em>%(subject)s</em> could not be found. The most likely
reason for this is that the list moderator has already approved or