Fix command-line ssh file transfer.

Patch submitted by Ron Cohen.
Merge branch 'fix-ssh-cli'