summaryrefslogtreecommitdiff
path: root/Mailman/Queue/CommandRunner.py
diff options
context:
space:
mode:
authorbwarsaw2001-09-05 02:41:37 +0000
committerbwarsaw2001-09-05 02:41:37 +0000
commit60e02b7852b4a5187ec7f06182b319434d9df0ec (patch)
treea96f1368e5eae11dcdca7eee75800876af359bb2 /Mailman/Queue/CommandRunner.py
parent48afd88903db89da42512b3739de1593c6932332 (diff)
downloadmailman-60e02b7852b4a5187ec7f06182b319434d9df0ec.tar.gz
mailman-60e02b7852b4a5187ec7f06182b319434d9df0ec.tar.zst
mailman-60e02b7852b4a5187ec7f06182b319434d9df0ec.zip
_dispose(): Reorganize the big if/elif/else switch so that it never
just short-circuit returns. We need to do this after moving the Save() into the try clause (which may turn out to not be the right thing to do...)
Diffstat (limited to 'Mailman/Queue/CommandRunner.py')
-rw-r--r--Mailman/Queue/CommandRunner.py16
1 files changed, 7 insertions, 9 deletions
diff --git a/Mailman/Queue/CommandRunner.py b/Mailman/Queue/CommandRunner.py
index d4bcabbf6..5bbd51d4a 100644
--- a/Mailman/Queue/CommandRunner.py
+++ b/Mailman/Queue/CommandRunner.py
@@ -96,11 +96,11 @@ class CommandRunner(Runner):
#
# See the diagram in IncomingRunner.py for more information.
if msgdata.get('toadmin'):
- if mlist.bounce_processing:
- if BouncerAPI.ScanMessages(mlist, msg):
- return
- self._toadmins(mlist, msg, msgdata)
- return
+ if mlist.bounce_processing and \
+ BouncerAPI.ScanMessages(mlist, msg):
+ pass
+ else:
+ self._toadmins(mlist, msg, msgdata)
elif msgdata.get('toowner'):
# The message could have been a bounce from a broken list
# owner address. About the only other test we can do is to
@@ -114,13 +114,11 @@ class CommandRunner(Runner):
senderlhs = sender
if senderlhs in mm_cfg.LIKELY_BOUNCE_SENDERS:
syslog('error', 'bounce loop detected from: %s', sender)
- return
- self._toadmins(mlist, msg, msgdata)
- return
+ else:
+ self._toadmins(mlist, msg, msgdata)
elif msgdata.get('torequest'):
# Just pass the message off the command handler
mlist.ParseMailCommands(msg, msgdata)
- return
elif msgdata.get('tojoin'):
del msg['subject']
msg['Subject'] = 'join'