P4DTI issue job001440

TitleWindows patches have bad line-endings
Statusclosed
Priorityessential
Assigned userNick Barnes
OrganizationRavenbrook
DescriptionThe patches for Bugzilla in the Windows P4DTI packages are broken: they have CR/LF line endings in the diff content but LF-only endings in the diff headers.
AnalysisThis was caused by installing Cygwin on our new development/test/build machines with the default Cygwin installation options (i.e. Unix line endings). The diff command sees the CRLF endings in the files it is diffing, so those get into the diff output. But the other lines generated by diff (identifying files and line numbers) are produced without Unix line endings.
This problem was not found in testing because the version of patch on the test machine was happy to cope with the mixed line endings.
Installing Cygwin with DOS line-endings lets us generate working patch files. Can we make working patch files even if we have Unix line endings? Surely it's a simple matter of using 'tr' (or Python) to make sure there's a CR before every LF.
How foundcustomer
Evidence[1] <http://info.ravenbrook.com/mail/2006/06/14/18-19-18/0.txt>
Observed in2.3.3
Introduced in2.3.3
Created byNick Barnes
Created on2006-06-15 11:00:55
Last modified byNick Barnes
Last modified on2006-06-15 11:11:18
History2006-06-15 NB Created.

Fixes

Change Effect Date User Description
159246 closed 2006-06-15 11:11:07 Nick Barnes Post-process diff files on Windows to tidy up line-endings. job001440.