Wrong return value when using /command option

Advertisement

elflord
Joined:
Posts:
1
Location:
Denmark

Wrong return value when using /command option

The return value is probably as it should be - I just fail to understand why. :(

My computer is Windows Server 2003 X64
My version of WinSCP is 4.2.9

When I use the command option in WinScp I would expect the return value to be 1 if just one of the commands are invalid. It doens't seem to be the case however.

Below is a (extremely) simple example:

C:\winscp429>WinSCP.exe /console /command "sds" "exit"
C:\winscp429>echo %errorlevel%
0


The first command is invalid, but still winScp returns 0 - can someone please explain why.
How can I be sure my dynamic scripting worked as planed?
I get the same result in a more advanced case where I connect to a sftp site with an invalid privatekey.

Reply with quote

Advertisement

Advertisement

You can post new topics in this forum