You actually need to have logging enabled to get this output. Setting logging level is not enough on its own. So this produces those lines:
I do not think there's any difference between 5.17.10 and 5.19.5 in this respect. You probably have logging enabled in 5.17.10 GUI. And as you do not isolate your script from the GUI configuration (
In any case, in all APIs I know, it's always easier to collect a process exit code than collecting and parsing the process output. You should not rely on parsing it. It's a debugging information. Its format can change in future.
WinSCP.com /ini=nul /command "exit" /loglevel=1 /log=winscp.log
I do not think there's any difference between 5.17.10 and 5.19.5 in this respect. You probably have logging enabled in 5.17.10 GUI. And as you do not isolate your script from the GUI configuration (
/ini=nul
in my example), it affects the script output. While in 5.19.5 you probably do not have logging enabled.
In any case, in all APIs I know, it's always easier to collect a process exit code than collecting and parsing the process output. You should not rely on parsing it. It's a debugging information. Its format can change in future.