diff options
author | Steven Knight <knight@baldmt.com> | 2010-05-25 15:27:45 +0000 |
---|---|---|
committer | Steven Knight <knight@baldmt.com> | 2010-05-25 15:27:45 +0000 |
commit | 4e26efd67bd35b1960ba69bc0580c9cc3af4f2f2 (patch) | |
tree | d6377b3593154226a11ce60b9d68138653ff2d59 /bin/time-scons.py | |
parent | e45890d4fde721a0677ed3791f9b0305c2b29794 (diff) | |
download | scons-4e26efd67bd35b1960ba69bc0580c9cc3af4f2f2.tar.gz |
Fix capturing timings from a single configuration script.
We were closing the output log file, thinking it was a per-script file,
even though we still write to the original log file for the revision.
Diffstat (limited to 'bin/time-scons.py')
-rw-r--r-- | bin/time-scons.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/bin/time-scons.py b/bin/time-scons.py index c0095e8b..b7d8ef17 100644 --- a/bin/time-scons.py +++ b/bin/time-scons.py @@ -260,13 +260,15 @@ def do_revisions(cr, opts, branch, revisions, scripts): lf = os.path.join(opts.origin, opts.logsdir, subdir, log_name) out = open(lf, 'w') err = None + close_out = True else: out = stdout err = stderr + close_out = False s = cr.run(script_command(script), stdout=out, stderr=err) if s and status == 0: status = s - if out not in (sys.stdout, None): + if close_out: out.close() out = None |