Author: bugman Date: Thu Oct 23 16:44:53 2008 New Revision: 7942 URL: http://svn.gna.org/viewcvs/relax?rev=7942&view=rev Log: Fix for the relax IO logging with the -l command line argument. This is a partial fix for bug #12489 (https://gna.org/bugs/?12489). The teeing problem still has to be fixed. Modified: 1.3/relax_io.py Modified: 1.3/relax_io.py URL: http://svn.gna.org/viewcvs/relax/1.3/relax_io.py?rev=7942&r1=7941&r2=7942&view=diff ============================================================================== --- 1.3/relax_io.py (original) +++ 1.3/relax_io.py Thu Oct 23 16:44:53 2008 @@ -184,6 +184,11 @@ # Log file. log_file, file_path = open_write_file(file_name=file_name, dir=dir, force=True, verbosity=verbosity, return_path=True) + # Logging IO streams. + log_stdin = stdin + log_stdout = None + log_stderr = SplitIO() + # Print out. if verbosity: print "Redirecting the sys.stdin IO stream to the python stdin IO stream." @@ -192,7 +197,8 @@ # Set the logging IO streams. log_stdout = log_file - log_stderr.split(python_stderr, log_file) + log_stderr = SplitIO() + log_stderr.split(stderr, log_file) # IO stream redirection. sys.stdin = log_stdin