summaryrefslogtreecommitdiff
path: root/diff-helper.c
diff options
context:
space:
mode:
authorJunio C Hamano <junkio@cox.net>2005-05-23 19:07:55 (GMT)
committerLinus Torvalds <torvalds@ppc970.osdl.org>2005-05-23 19:17:09 (GMT)
commit5831b563a442e7c3198a444a51d8caba4d072506 (patch)
tree770a89b014c4df5b3320e1c8bdd5a39abb719646 /diff-helper.c
parent046aa6440fdf9a94df5e2f0609bef5d7415ff94a (diff)
downloadgit-5831b563a442e7c3198a444a51d8caba4d072506.zip
git-5831b563a442e7c3198a444a51d8caba4d072506.tar.gz
git-5831b563a442e7c3198a444a51d8caba4d072506.tar.bz2
[PATCH] NUL terminate diff-tree header lines under -z.
Thomas Glanzmann noticed that diff-tree -z HEAD piped to diff-helper -z did not work. Since diff-helper -z expects NUL terminated lines, we should generate such. The output side of the diff-helper should always be using '\n' termination; earlier it used the same line_termination used for the input side, which was a mistake. Signed-off-by: Junio C Hamano <junkio@cox.net> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'diff-helper.c')
-rw-r--r--diff-helper.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/diff-helper.c b/diff-helper.c
index 2385575..c977a1b 100644
--- a/diff-helper.c
+++ b/diff-helper.c
@@ -121,7 +121,7 @@ int main(int ac, const char **av) {
if (status) {
unrecognized:
diff_flush(diff_output_style);
- printf("%s%c", sb1.buf, line_termination);
+ printf("%s\n", sb1.buf);
}
}
if (detect_rename)