From 18323f5b485f5c484622e18c6bfd167fdf5ca101 Mon Sep 17 00:00:00 2001 From: Patrick Steinhardt Date: Thu, 17 Jul 2025 06:56:28 +0200 Subject: object-file: stop using `the_hash_algo` There are a couple of users of the `the_hash_algo` macro, which implicitly depends on `the_repository`. Adapt these callers to not do so anymore, either by deriving it from already-available context or by using `the_repository->hash_algo`. The latter variant doesn't yet help to remove the global dependency, but such users will be adapted in the following commits to not use `the_repository` anymore. Signed-off-by: Patrick Steinhardt Signed-off-by: Junio C Hamano --- object-file.h | 1 + 1 file changed, 1 insertion(+) (limited to 'object-file.h') diff --git a/object-file.h b/object-file.h index 67b4ffc480..222ff2871a 100644 --- a/object-file.h +++ b/object-file.h @@ -89,6 +89,7 @@ typedef int each_loose_subdir_fn(unsigned int nr, void *data); int for_each_file_in_obj_subdir(unsigned int subdir_nr, struct strbuf *path, + const struct git_hash_algo *algo, each_loose_object_fn obj_cb, each_loose_cruft_fn cruft_cb, each_loose_subdir_fn subdir_cb, -- cgit v1.3-6-g1900