Commit Diff
- Commit:
f46fa9b5e78156c0360f508336dbe3dfa04b503f
- From:
- Christian Weisgerber <naddy@mips.inka.de>
- Date:
- Message:
- do not treat \r\n line endings as special Previously, we would go out of our way to handle both \n and \r\n line endings as equivalent. However, for files with \r\n line endings, this results in diffs that omit the final \r and therefore cannot be applied with patch(1) on Unix platforms. ok stsp
- Actions:
- Patch | Tree
--- lib/diff_output.c +++ lib/diff_output.c @@ -90,13 +90,6 @@ diff_output_lines(struct diff_output_info *outinfo, FI return rc; if (ch == '\n') len--; - if (len) { - rc = get_atom_byte(&ch, atom, len - 1); - if (rc) - return rc; - if (ch == '\r') - len--; - } } for (i = 0; i < len; i++) {