aboutsummaryrefslogtreecommitdiffstats
path: root/builtin/receive-pack.c
diff options
context:
space:
mode:
authorÆvar Arnfjörð Bjarmason <avarab@gmail.com>2023-03-28 15:58:47 +0200
committerJunio C Hamano <gitster@pobox.com>2023-03-28 07:36:36 -0700
commitcb338c23d6d518947bf6f7240bf30e2ec232bd3b (patch)
tree03396382848bae350d813b706265918cd93f1ba2 /builtin/receive-pack.c
parentcocci: apply the "cache.h" part of "the_repository.pending" (diff)
downloadgit-cb338c23d6d518947bf6f7240bf30e2ec232bd3b.tar.gz
git-cb338c23d6d518947bf6f7240bf30e2ec232bd3b.zip
cocci: apply the "commit-reach.h" part of "the_repository.pending"
Apply the part of "the_repository.pending.cocci" pertaining to "commit-reach.h". Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin/receive-pack.c')
-rw-r--r--builtin/receive-pack.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/builtin/receive-pack.c b/builtin/receive-pack.c
index b5816624d2..6d4fc1368a 100644
--- a/builtin/receive-pack.c
+++ b/builtin/receive-pack.c
@@ -1548,7 +1548,7 @@ static const char *update(struct command *cmd, struct shallow_info *si)
}
old_commit = (struct commit *)old_object;
new_commit = (struct commit *)new_object;
- if (!in_merge_bases(old_commit, new_commit)) {
+ if (!repo_in_merge_bases(the_repository, old_commit, new_commit)) {
rp_error("denying non-fast-forward %s"
" (you should pull first)", name);
ret = "non-fast-forward";