Post a reply

Options
Add an Attachment

If you do not want to add an Attachment to your Post, please leave the Fields blank.

(maximum 10 MB; please compress large files; only common media, archive, text and programming file formats are allowed)

Options

Topic review

cosb

Files are uploaded with 0kb

Hello,
We use the .Net assembly to upload files to a remote SFTP server via a custom c# app. The component has the version 1.16.0.16364 and it uses WinScp 6.5.3. Recently, we had a case where a file was uploaded with 0KB. The component didn't report any errors in the app, so as far as our app was concerned the transfer was successful. Other files and lots of them were transferred properly.
Is there a way for our app to double-check the size of the uploaded file to make sure it was not 0kb and re-try the transfer if that's the case? The files are small, in this particular case the file had 1,722 bytes.
I also searched the forum and there have been other posts in the past about this very issue.
Here are 2 I found:
https://winscp.net/forum/viewtopic.php?t=28632
https://winscp.net/forum/viewtopic.php?t=27865
It seems to me that the server software was the culprit in these cases. We are going to explore that side as well but it belongs to third-party and I don't know exactly what they use and how responsive they are.
Could you please let me know if there is anything I can do in the app to detect a 0kb file upload and to re-try the transfer in this scenario? I want to make sure the transfers are foolproof.

Thank you so much!