mirror of
https://github.com/PowerShell/Win32-OpenSSH.git
synced 2025-07-21 21:14:51 +02:00
Fix #ifdef for WINDOWS
This commit is contained in:
parent
e3ad6f1c65
commit
6e9b4202ee
7
scp.c
7
scp.c
@ -1547,6 +1547,7 @@ syserr: run_err("%s: %s", name, strerror(errno));
|
|||||||
run_err("%s: not a regular file", name);
|
run_err("%s: not a regular file", name);
|
||||||
goto next;
|
goto next;
|
||||||
}
|
}
|
||||||
|
#ifdef WINDOWS
|
||||||
if ((lastf = strrchr(name, '/')) == NULL && (lastr = strrchr(name, '\\')) == NULL)
|
if ((lastf = strrchr(name, '/')) == NULL && (lastr = strrchr(name, '\\')) == NULL)
|
||||||
last = name;
|
last = name;
|
||||||
else {
|
else {
|
||||||
@ -1556,6 +1557,12 @@ syserr: run_err("%s: %s", name, strerror(errno));
|
|||||||
last = lastr;
|
last = lastr;
|
||||||
++last;
|
++last;
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
if ((last = strrchr(name, '/')) == NULL)
|
||||||
|
last = name;
|
||||||
|
else
|
||||||
|
++last;
|
||||||
|
#endif
|
||||||
curfile = last;
|
curfile = last;
|
||||||
if (pflag) {
|
if (pflag) {
|
||||||
if (do_times(remout, verbose_mode, &stb) < 0)
|
if (do_times(remout, verbose_mode, &stb) < 0)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user