diff options
author | Ævar Arnfjörð Bjarmason <avarab@gmail.com> | 2023-03-28 15:58:46 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2023-03-28 16:36:36 +0200 |
commit | d850b7a545fcfbd97460a921c7f7c59d933eb0f7 (patch) | |
tree | e36940d63b92557a8d930301ff96e70e55cc222d /log-tree.c | |
parent | cocci: add missing "the_repository" macros to "pending" (diff) | |
download | git-d850b7a545fcfbd97460a921c7f7c59d933eb0f7.tar.xz git-d850b7a545fcfbd97460a921c7f7c59d933eb0f7.zip |
cocci: apply the "cache.h" part of "the_repository.pending"
Apply the part of "the_repository.pending.cocci" pertaining to
"cache.h".
Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'log-tree.c')
-rw-r--r-- | log-tree.c | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/log-tree.c b/log-tree.c index 1dd5fcbf7b..f36adb947e 100644 --- a/log-tree.c +++ b/log-tree.c @@ -233,7 +233,8 @@ static void show_parents(struct commit *commit, int abbrev, FILE *file) struct commit_list *p; for (p = commit->parents; p ; p = p->next) { struct commit *parent = p->item; - fprintf(file, " %s", find_unique_abbrev(&parent->object.oid, abbrev)); + fprintf(file, " %s", + repo_find_unique_abbrev(the_repository, &parent->object.oid, abbrev)); } } @@ -241,7 +242,8 @@ static void show_children(struct rev_info *opt, struct commit *commit, int abbre { struct commit_list *p = lookup_decoration(&opt->children, &commit->object); for ( ; p; p = p->next) { - fprintf(opt->diffopt.file, " %s", find_unique_abbrev(&p->item->object.oid, abbrev)); + fprintf(opt->diffopt.file, " %s", + repo_find_unique_abbrev(the_repository, &p->item->object.oid, abbrev)); } } @@ -644,7 +646,8 @@ void show_log(struct rev_info *opt) if (!opt->graph) put_revision_mark(opt, commit); - fputs(find_unique_abbrev(&commit->object.oid, abbrev_commit), opt->diffopt.file); + fputs(repo_find_unique_abbrev(the_repository, &commit->object.oid, abbrev_commit), + opt->diffopt.file); if (opt->print_parents) show_parents(commit, abbrev_commit, opt->diffopt.file); if (opt->children.name) @@ -706,8 +709,8 @@ void show_log(struct rev_info *opt) if (!opt->graph) put_revision_mark(opt, commit); - fputs(find_unique_abbrev(&commit->object.oid, - abbrev_commit), + fputs(repo_find_unique_abbrev(the_repository, &commit->object.oid, + abbrev_commit), opt->diffopt.file); if (opt->print_parents) show_parents(commit, abbrev_commit, opt->diffopt.file); @@ -715,7 +718,7 @@ void show_log(struct rev_info *opt) show_children(opt, commit, abbrev_commit); if (parent) fprintf(opt->diffopt.file, " (from %s)", - find_unique_abbrev(&parent->object.oid, abbrev_commit)); + repo_find_unique_abbrev(the_repository, &parent->object.oid, abbrev_commit)); fputs(diff_get_color_opt(&opt->diffopt, DIFF_RESET), opt->diffopt.file); show_decorations(opt, commit); if (opt->commit_format == CMIT_FMT_ONELINE) { |