diff: correct newline in summary for renamed files
commit58aaced4442a6daae1c82318f3f9259001714505
authorStefan Beller <sbeller@google.com>
Wed, 27 Sep 2017 22:51:26 +0000 (27 15:51 -0700)
committerJunio C Hamano <gitster@pobox.com>
Thu, 28 Sep 2017 04:15:59 +0000 (28 13:15 +0900)
tree07533df7a29931396385cc552eafe62cc2ef42d5
parent61e89eaae8824926dc03c47e6ab3aa990b5b832e
diff: correct newline in summary for renamed files

In 146fdb0dfe (diff.c: emit_diff_symbol learns about DIFF_SYMBOL_SUMMARY,
2017-06-29), the conversion from direct printing to the symbol emission
dropped the new line character for renamed, copied and rewritten files.

Add the emission of a newline, add a test for this case.

Reported-by: Linus Torvalds <torvalds@linux-foundation.org>
Helped-by: Jeff King <peff@peff.net>
Signed-off-by: Stefan Beller <sbeller@google.com>
Reviewed-by: Jonathan Nieder <jrnieder@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
diff.c
t/t4013-diff-various.sh
t/t4013/diff.diff-tree_--stat_initial_mode [new file with mode: 0644]
t/t4013/diff.diff-tree_--summary_initial_mode [new file with mode: 0644]
t/t4013/diff.diff-tree_initial_mode [new file with mode: 0644]
t/t4013/diff.log_--decorate=full_--all
t/t4013/diff.log_--decorate_--all