From: Mark Wooding Date: Mon, 27 Feb 2006 12:52:52 +0000 (+0000) Subject: combine-diff: Honour -z option correctly. X-Git-Tag: v1.2.4~4 X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=feffaddce0cec7fd3f749d23e95579b683961002;p=git.git combine-diff: Honour -z option correctly. Combined diffs don't null terminate things in the same way as standard diffs. This is presumably wrong. Signed-off-by: Mark Wooding Signed-off-by: Junio C Hamano (cherry picked from 6baf0484efcd29bb5e58ccd5ea0379481d4a83f4 commit) --- diff --git a/combine-diff.c b/combine-diff.c index 984103edc..a23894d86 100644 --- a/combine-diff.c +++ b/combine-diff.c @@ -726,7 +726,7 @@ static int show_patch_diff(struct combine_diff_path *elem, int num_parent, if (header) { shown_header++; - puts(header); + printf("%s%c", header, opt->line_termination); } printf("diff --%s ", dense ? "cc" : "combined"); if (quote_c_style(elem->path, NULL, NULL, 0)) @@ -799,7 +799,7 @@ static void show_raw_diff(struct combine_diff_path *p, int num_parent, const cha inter_name_termination = 0; if (header) - puts(header); + printf("%s%c", header, line_termination); for (i = 0; i < num_parent; i++) { if (p->parent[i].mode)