diff options
author | Stefan Beller <sbeller@google.com> | 2018-04-12 02:21:15 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2018-04-12 04:38:56 +0200 |
commit | 0d296c57aec3a2c311abc5ebe7d1499bc41bc9df (patch) | |
tree | 8ba4e30ae980a0d34719725ab03c7ad2f38e5db8 /refs.c | |
parent | refs: store the main ref store inside the repository struct (diff) | |
download | git-0d296c57aec3a2c311abc5ebe7d1499bc41bc9df.tar.xz git-0d296c57aec3a2c311abc5ebe7d1499bc41bc9df.zip |
refs: allow for_each_replace_ref to handle arbitrary repositories
Signed-off-by: Stefan Beller <sbeller@google.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'refs.c')
-rw-r--r-- | refs.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -1415,9 +1415,9 @@ int refs_for_each_fullref_in(struct ref_store *refs, const char *prefix, return do_for_each_ref(refs, prefix, fn, 0, flag, cb_data); } -int for_each_replace_ref_the_repository(each_ref_fn fn, void *cb_data) +int for_each_replace_ref(struct repository *r, each_ref_fn fn, void *cb_data) { - return do_for_each_ref(get_main_ref_store(the_repository), + return do_for_each_ref(get_main_ref_store(r), git_replace_ref_base, fn, strlen(git_replace_ref_base), DO_FOR_EACH_INCLUDE_BROKEN, cb_data); |