diff options
| author | bwarsaw | 2001-07-10 14:28:12 +0000 |
|---|---|---|
| committer | bwarsaw | 2001-07-10 14:28:12 +0000 |
| commit | 070b0a8153e7c659cc49eece914d9c2ec747e470 (patch) | |
| tree | 300df157921bc3887881299b2ba0d9d677e137f7 /Mailman/Queue/IncomingRunner.py | |
| parent | b51825e817f41bedf897ba28f455c47ca972b3f4 (diff) | |
| download | mailman-070b0a8153e7c659cc49eece914d9c2ec747e470.tar.gz mailman-070b0a8153e7c659cc49eece914d9c2ec747e470.tar.zst mailman-070b0a8153e7c659cc49eece914d9c2ec747e470.zip | |
Diffstat (limited to 'Mailman/Queue/IncomingRunner.py')
| -rw-r--r-- | Mailman/Queue/IncomingRunner.py | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/Mailman/Queue/IncomingRunner.py b/Mailman/Queue/IncomingRunner.py index 2cb349be5..462daf066 100644 --- a/Mailman/Queue/IncomingRunner.py +++ b/Mailman/Queue/IncomingRunner.py @@ -98,7 +98,6 @@ class IncomingRunner(Runner): except LockFile.TimeOutError: # Oh well, try again later return 1 - # # Process the message through a handler pipeline. The handler # pipeline can actually come from one of three places: the message # metadata, the mlist, or the global pipeline. @@ -130,10 +129,9 @@ class IncomingRunner(Runner): handler = pipeline.pop(0) modname = 'Mailman.Handlers.' + handler mod = __import__(modname) - func = getattr(sys.modules[modname], 'process') try: pid = os.getpid() - func(mlist, msg, msgdata) + sys.modules[modname].process(mlist, msg, msgdata) # Failsafe -- a child may have leaked through. if pid <> os.getpid(): syslog('error', 'child process leaked thru: %s', modname) @@ -141,10 +139,13 @@ class IncomingRunner(Runner): except Errors.DiscardMessage: # Throw the message away; we need do nothing else with it. return 0 - except Errors.MessageHeld: + except Errors.HoldMessage: # Let the approval process take it from here. The message no # longer needs to be queued. return 0 + except Errors.RejectMessage, e: + mlist.BounceMessage(msg, msgdata, e) + return 0 except Exception, e: # Some other exception occurred, which we definitely did not # expect, so set this message up for requeuing. |
