Topic "WinSCP changing encoding of files"

Author Message
winbug

Guest


I am pulling files from my Ubuntu system to my Windows machine and it would appears that the files are being modified by WinSCP. It would appear that either the content or the line end (I suspect the latter) is being changed. For example, when you do a diff of the original and the transmitted file, the text content is the same, but all lines are flagged up as changed.

Is there any way to turn this behavior off so that the file is copied over intact? I've tried changing the end of line option to LF and turning off UTF-8 encoding (they already are UTF-Cool, and even changing the protocol to SCP as it does not support encoding, but this made no difference.

I was finally able to get around the problem by copying the file using SCP in Cygwin.
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 25015
Location: Prague, Czechia
Please read FAQ:
https://winscp.net/eng/docs/faq_transfer_size_change
_________________
Martin Prikryl
winbug

Guest


Thank you for this.

As this reminded me, when doing an FTP transfer manually you have to use a BI command to set the file transfer to mode to binary mode otherwise strange things happen to the files. Here we are using SFTP which is FTP encapsulated in a secure protocol so the same applies. I found the Transfer Mode option in Other General Options under Preferences and changed this from Auto to Binary and tried again. The transferred files now appear to be getting copied over intact so it would seem that the problem is solved.

Smile
Advertisements

You can post new topics in this forum






Search Site

What is WinSCP?

It is award-winning SFTP client, SCP client, FTPS client and FTP client integrated into one software program for file transfer to FTP server or secure SFTP server. [More]

And it's free!

Donate

About donations

$9   $19   $49   $99

About donations

Recommend

WinSCP Privacy Policy

WinSCP License