summaryrefslogtreecommitdiff
path: root/log-tree.c
diff options
context:
space:
mode:
authorElijah Newren <newren@gmail.com>2022-02-02 02:37:34 +0000
committerJunio C Hamano <gitster@pobox.com>2022-02-02 10:02:28 -0800
commit95433eeed9eac439eb21eb30105354b15e71302e (patch)
tree7eda4d13eb4ff66943c75658774038eea4f9ac8e /log-tree.c
parent6054d1aac36d5769461fb73b15326a900e53edb9 (diff)
downloadgit-95433eeed9eac439eb21eb30105354b15e71302e.tar.gz
diff: add ability to insert additional headers for paths
When additional headers are provided, we need to * add diff_filepairs to diff_queued_diff for each paths in the additional headers map which, unless that path is part of another diff_filepair already found in diff_queued_diff * format the headers (colorization, line_prefix for --graph) * make sure the various codepaths that attempt to return early if there are "no changes" take into account the headers that need to be shown. Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'log-tree.c')
-rw-r--r--log-tree.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/log-tree.c b/log-tree.c
index 6b62ae1a6b..fe2084625e 100644
--- a/log-tree.c
+++ b/log-tree.c
@@ -852,7 +852,7 @@ int log_tree_diff_flush(struct rev_info *opt)
opt->shown_dashes = 0;
diffcore_std(&opt->diffopt);
- if (diff_queue_is_empty()) {
+ if (diff_queue_is_empty(&opt->diffopt)) {
int saved_fmt = opt->diffopt.output_format;
opt->diffopt.output_format = DIFF_FORMAT_NO_OUTPUT;
diff_flush(&opt->diffopt);