Author: bugman Date: Thu Mar 22 10:57:51 2012 New Revision: 15603 URL: http://svn.gna.org/viewcvs/relax?rev=15603&view=rev Log: The multi-processor package now allows sys.exit() calls within the master processor. This affects all processor fabrics, as the Processor.run() method has been modified. The SystemExit exception is now specifically caught on the master. The Processor.exit() method is then called to allow the specific fabric to clean up, if needed, and then the SystemExit is re-raised to allow the system exit to proceed as normal. Modified: 1.3/multi/processor.py Modified: 1.3/multi/processor.py URL: http://svn.gna.org/viewcvs/relax/1.3/multi/processor.py?rev=15603&r1=15602&r2=15603&view=diff ============================================================================== --- 1.3/multi/processor.py (original) +++ 1.3/multi/processor.py Thu Mar 22 10:57:51 2012 @@ -437,6 +437,14 @@ try: self.callback.init_master(self) + # Allow sys.exit() calls. + except SystemExit: + # Allow the processor fabric to clean up. + self.exit() + + # Continue with the sys.exit(). + raise + # Handle all errors nicely. except Exception, e: self.callback.handle_exception(self, e)