summaryrefslogtreecommitdiff
path: root/builtin/update-index.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2024-05-16 10:10:13 -0700
committerJunio C Hamano <gitster@pobox.com>2024-05-16 10:10:14 -0700
commitbca900904d854babf2493d57c0fee3ab421fe750 (patch)
treee664fba784c58d391ddf22c32222b0212b670171 /builtin/update-index.c
parentf0e2183768b1548bcaea9e311bb5a54112c0a9f4 (diff)
parentc8f815c2083c4b340d4148a15d45c55f2fcc7d3f (diff)
Merge branch 'ps/refs-without-the-repository'
The refs API lost functions that implicitly assumes to work on the primary ref_store by forcing the callers to pass a ref_store as an argument. * ps/refs-without-the-repository: refs: remove functions without ref store cocci: apply rules to rewrite callers of "refs" interfaces cocci: introduce rules to transform "refs" to pass ref store refs: add `exclude_patterns` parameter to `for_each_fullref_in()` refs: introduce missing functions that accept a `struct ref_store`
Diffstat (limited to 'builtin/update-index.c')
-rw-r--r--builtin/update-index.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/builtin/update-index.c b/builtin/update-index.c
index 6321810006..20aa1c4c68 100644
--- a/builtin/update-index.c
+++ b/builtin/update-index.c
@@ -682,7 +682,7 @@ static int do_reupdate(const char **paths,
PATHSPEC_PREFER_CWD,
prefix, paths);
- if (read_ref("HEAD", &head_oid))
+ if (refs_read_ref(get_main_ref_store(the_repository), "HEAD", &head_oid))
/* If there is no HEAD, that means it is an initial
* commit. Update everything in the index.
*/