diff options
author | JingLu5 <lvjing5@huawei.com> | 2016-12-20 10:46:26 +0800 |
---|---|---|
committer | JingLu5 <lvjing5@huawei.com> | 2016-12-20 11:08:02 +0800 |
commit | dcc1818e66580808de9e427812a1c82f7e0673ff (patch) | |
tree | 178272dce574ef842aba41ac4a95fbe2b9b86366 /yardstick/ssh.py | |
parent | 367691281be05a5f2c76455465ff14078415e6c2 (diff) |
BugFix: remotepath cannot be found
JIRA: YARDSTICK-501
An redundant pair of quotation in ssh.py causes remotepath cannot be found.
Change-Id: I2df8ab59830fd28d8ad8882a93a8efbd4d1f7cb7
Signed-off-by: JingLu5 <lvjing5@huawei.com>
Diffstat (limited to 'yardstick/ssh.py')
-rw-r--r-- | yardstick/ssh.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/yardstick/ssh.py b/yardstick/ssh.py index 2ba6de92e..3081001b6 100644 --- a/yardstick/ssh.py +++ b/yardstick/ssh.py @@ -313,14 +313,14 @@ class SSH(object): def _put_file_shell(self, localpath, remotepath, mode=None): # quote to stop wordpslit - cmd = ['cat > "%s"' % remotepath] + cmd = ['cat > %s' % remotepath] if mode is not None: # use -- so no options - cmd.append('chmod -- 0%o "%s"' % (mode, remotepath)) + cmd.append('chmod -- 0%o %s' % (mode, remotepath)) with open(localpath, "rb") as localfile: # only chmod on successful cat - cmd = "&& ".join(cmd) + cmd = " && ".join(cmd) self.run(cmd, stdin=localfile) def put_file(self, localpath, remotepath, mode=None): |