[PATCH] Allow scp to copy files that start with a Windows drive name.
scott_n at xypro.com
Wed Sep 21 01:35:23 AEST 2016
On Windows, “scp C:/foo/bar remotehost:” will attempt to connect to a remote host “C”
and access file “/foo/bar”. There is currently no syntax or flag to allow copying files that start with a drive name.
This patch changes the behaviour (only on Cygwin) by considering that a single letter followed by a colon is a Windows drive name and thus an absolute path. This is also more consistent with the manual page that recommends to use absolute pathnames “to avoid scp treating file names containing ‘:’ as host specifiers”.
Is this really necessary? Especially since it's a Cygwin specific patch, what is wrong with simply using /cygdrive/C/foo/bar?
More information about the openssh-unix-dev