Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorÆvar Arnfjörð Bjarmason <avarab@gmail.com>2023-03-28 16:58:46 +0300
committerJunio C Hamano <gitster@pobox.com>2023-03-28 17:36:36 +0300
commitd850b7a545fcfbd97460a921c7f7c59d933eb0f7 (patch)
treee36940d63b92557a8d930301ff96e70e55cc222d /log-tree.c
parent7258e892d2c0f7a615562656e9978f39f610c056 (diff)
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.c15
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) {