Peter Balogh


Found
r1207663

r1207663 | stsp | 2011-11-28 22:34:49 +0000 (Mon, 28 Nov 2011)

Make the diff parser handle comment lines indicating missing EOLs if such
comments appear within the diff text of a hunk, not just at the very end
of the hunk's diff text.

Reported by: Peter Balogh
http://svn.haxx.se/users/archive-2011-11/0523.shtml

* subversion/libsvn_diff/parse-diff.c
  (parse_next_hunk): The '\ No newline at end of ...' comments may appear
   not only at the very end of a hunk text, but also at the end of the
   original version (the last line starting with '-') or at the end of the
   modified version (the last line starting with '+') of the hunk text.
   Properly account for this by keeping track of the last byte in the
   original and modified hunk texts independently.

* subversion/tests/cmdline/patch_tests.py
  (patch_target_no_eol_at_eof, test_list): New test.