scp: add test case and document remote to remote transfers

This commit is contained in:
Nicola Murino
2019-08-25 13:51:54 +02:00
parent 1c5aac0dc4
commit d4969cde03
4 changed files with 79 additions and 24 deletions

View File

@@ -695,7 +695,8 @@ func (c *scpCommand) getFileUploadDestPath(scpDestPath, fileName string) string
return scpDestPath
}
}
// if the upload is recursive then the destination file is relative to the current scpDestPath
// if the upload is recursive or scpDestPath has the "/" suffix then the destination
// file is relative to scpDestPath
return path.Join(scpDestPath, fileName)
}