summaryrefslogtreecommitdiff
path: root/builtin/submodule--helper.c
diff options
context:
space:
mode:
authorÆvar Arnfjörð Bjarmason <avarab@gmail.com>2023-03-28 13:58:46 (GMT)
committerJunio C Hamano <gitster@pobox.com>2023-03-28 14:36:36 (GMT)
commitd850b7a545fcfbd97460a921c7f7c59d933eb0f7 (patch)
treee36940d63b92557a8d930301ff96e70e55cc222d /builtin/submodule--helper.c
parent7258e892d2c0f7a615562656e9978f39f610c056 (diff)
downloadgit-d850b7a545fcfbd97460a921c7f7c59d933eb0f7.zip
git-d850b7a545fcfbd97460a921c7f7c59d933eb0f7.tar.gz
git-d850b7a545fcfbd97460a921c7f7c59d933eb0f7.tar.bz2
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 'builtin/submodule--helper.c')
-rw-r--r--builtin/submodule--helper.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/builtin/submodule--helper.c b/builtin/submodule--helper.c
index 4c173d8..25c70f4 100644
--- a/builtin/submodule--helper.c
+++ b/builtin/submodule--helper.c
@@ -1174,7 +1174,7 @@ static int module_summary(int argc, const char **argv, const char *prefix)
if (!summary_limit)
return 0;
- if (!get_oid(argc ? argv[0] : "HEAD", &head_oid)) {
+ if (!repo_get_oid(the_repository, argc ? argv[0] : "HEAD", &head_oid)) {
if (argc) {
argv++;
argc--;
@@ -1187,7 +1187,7 @@ static int module_summary(int argc, const char **argv, const char *prefix)
argc--;
}
} else {
- if (get_oid("HEAD", &head_oid))
+ if (repo_get_oid(the_repository, "HEAD", &head_oid))
die(_("could not fetch a revision for HEAD"));
}