diff options
| author | Patrick Steinhardt <ps@pks.im> | 2026-01-26 10:51:23 +0100 |
|---|---|---|
| committer | Junio C Hamano <gitster@pobox.com> | 2026-01-26 08:26:07 -0800 |
| commit | df2fbdfa553526062e5234286f60bd643941298a (patch) | |
| tree | 84c0145fb135bea7ff9a23dcddd35f5a05be9bd1 /object-file.h | |
| parent | 736464b84f4439361ec10e9ef49bff674fea952d (diff) | |
| download | git-df2fbdfa553526062e5234286f60bd643941298a.tar.xz | |
odb: introduce `odb_for_each_object()`
Introduce a new function `odb_for_each_object()` that knows to iterate
through all objects part of a given object database. This function is
essentially a simple wrapper around the object database sources.
Subsequent commits will adapt callers to use this new function.
Signed-off-by: Patrick Steinhardt <ps@pks.im>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'object-file.h')
| -rw-r--r-- | object-file.h | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/object-file.h b/object-file.h index 5b9641cd89..b5eac0349e 100644 --- a/object-file.h +++ b/object-file.h @@ -139,9 +139,10 @@ int for_each_loose_object(struct object_database *odb, /* * Iterate through all loose objects in the given object database source and - * invoke the callback function for each of them. If given, the object info - * will be populated with the object's data as if you had called - * `odb_source_loose_read_object_info()` on the object. + * invoke the callback function for each of them. If an object info request is + * given, then the object info will be read for every individual object and + * passed to the callback as if `odb_source_loose_read_object_info()` was + * called for the object. */ int odb_source_loose_for_each_object(struct odb_source *source, const struct object_info *request, |
