Fix logic from 4a5b924d37 (which was still wrong after 4410f91dad)

This commit is contained in:
Eduard Braun 2016-09-25 15:34:28 +02:00
parent 91ee9d2112
commit 2fe7152a1e

View file

@ -3794,9 +3794,9 @@ def start(options, input, output):
output.write(out_string) output.write(out_string)
# Close input and output files (but do not attempt to close stdin/stdout!) # Close input and output files (but do not attempt to close stdin/stdout!)
if not ((input is sys.stdin) or (hasattr(input, 'buffer') and input is sys.stdin.buffer)): if not ((input is sys.stdin) or (hasattr(sys.stdin, 'buffer') and input is sys.stdin.buffer)):
input.close() input.close()
if not ((output is sys.stdout) or (hasattr(output, 'buffer') and output is sys.stdout.buffer)): if not ((output is sys.stdout) or (hasattr(sys.stdout, 'buffer') and output is sys.stdout.buffer)):
output.close() output.close()
end = walltime() end = walltime()