diff options
author | Eric Sunshine <sunshine@sunshineco.com> | 2018-07-22 11:57:10 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2018-08-14 23:24:56 +0200 |
commit | 87f1b2d45ca7987cc6cc1a74eb66a77fa11fab94 (patch) | |
tree | e38ddf762e28fc555c4e4a41169428b7979507cb /range-diff.c | |
parent | Merge branch 'es/format-patch-interdiff' into es/format-patch-rangediff (diff) | |
download | git-87f1b2d45ca7987cc6cc1a74eb66a77fa11fab94.tar.xz git-87f1b2d45ca7987cc6cc1a74eb66a77fa11fab94.zip |
range-diff: respect diff_option.file rather than assuming 'stdout'
The actual diffs output by range-diff respect diff_option.file, which
range-diff passes down the call-chain, thus are destination-agnostic.
However, output_pair_header() is hard-coded to emit to 'stdout'. Fix
this by making output_pair_header() respect diff_option.file, as well.
Signed-off-by: Eric Sunshine <sunshine@sunshineco.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'range-diff.c')
-rw-r--r-- | range-diff.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/range-diff.c b/range-diff.c index b6b9abac26..defe31f095 100644 --- a/range-diff.c +++ b/range-diff.c @@ -323,7 +323,7 @@ static void output_pair_header(struct diff_options *diffopt, } strbuf_addf(buf, "%s\n", color_reset); - fwrite(buf->buf, buf->len, 1, stdout); + fwrite(buf->buf, buf->len, 1, diffopt->file); } static struct userdiff_driver no_func_name = { |