diff options
author | jadmanski <jadmanski@592f7852-d20e-0410-864c-8624ca9c26a4> | 2009-04-10 17:43:12 +0000 |
---|---|---|
committer | jadmanski <jadmanski@592f7852-d20e-0410-864c-8624ca9c26a4> | 2009-04-10 17:43:12 +0000 |
commit | d31d89f0c286703431d5b17f2012adba1d264d3c (patch) | |
tree | 3bb8c7e81a651e9398df4a94ed46b611970baaa5 /server/hosts | |
parent | c1433ad6f621b893c219b62543fdd9bc03c6aa48 (diff) |
Fix up a "bug" in ParamikoHost where reading std* streams after closing
the remote channel can end up returning while data is still arriving,
resulting in truncated std*.
Risk: Medium
Visibility: Should fix some weird remote command truncation issues.
Signed-off-by: John Admanski <jadmanski@google.com>
git-svn-id: svn://test.kernel.org/autotest/trunk@2983 592f7852-d20e-0410-864c-8624ca9c26a4
Diffstat (limited to 'server/hosts')
-rw-r--r-- | server/hosts/paramiko_host.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/server/hosts/paramiko_host.py b/server/hosts/paramiko_host.py index 53a89e3d..619f172f 100644 --- a/server/hosts/paramiko_host.py +++ b/server/hosts/paramiko_host.py @@ -202,9 +202,9 @@ class ParamikoHost(abstract_ssh.AbstractSSHHost): exit_status = -signal.SIGTERM else: exit_status = channel.recv_exit_status() - channel.close() self._exhaust_stream(stdout, raw_stdout, channel.recv) self._exhaust_stream(stderr, raw_stderr, channel.recv_stderr) + channel.close() duration = time.time() - start_time # create the appropriate results |