When downloading files with CR+LF line endings from a Linux server in ASCII mode, extra CR bytes may occasionally be added incorrectly. This issue seems to occur when there are two consecutive CR+LF sequences located at specific offsets close to 32KB or any multiple of 32K.
Seems to be similar to these fixed issues,
Issue 1059 – Rare incorrect conversion of line endings and
Issue 845 – Rare incorrect conversion of line endings.
WinSCP version: 6.3.5 (also tested 6.4 beta and some older versions)
OS: Windows 10/11
Protocol: SFTP-3
Attached some files for testing.
Steps to reproduce:
- Upload one of the test files to Linux server in Binary mode
- Download it from Linux server in Text mode
- Compare to original file to see that additional CR byte(s) will have been added
Hope this explains the issue, let me know if you need me to test anything.