diff options
| author | Patrick Steinhardt <ps@pks.im> | 2026-03-05 15:19:48 +0100 |
|---|---|---|
| committer | Junio C Hamano <gitster@pobox.com> | 2026-03-05 11:45:15 -0800 |
| commit | 3bc3177ad7a472dd5fc45cff16b8f57e5800ebc2 (patch) | |
| tree | de69cb8d12c523123cbe61a6bb0e069811f269a7 /odb.c | |
| parent | 05151cf3602d5ebaaa4e04c415e8481cb1c7ddf6 (diff) | |
| download | git-3bc3177ad7a472dd5fc45cff16b8f57e5800ebc2.tar.xz | |
odb/source: make `close()` function pluggable
Introduce a new callback function in `struct odb_source` to make the
function pluggable.
Signed-off-by: Patrick Steinhardt <ps@pks.im>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'odb.c')
| -rw-r--r-- | odb.c | 6 |
1 files changed, 2 insertions, 4 deletions
@@ -1062,10 +1062,8 @@ struct object_database *odb_new(struct repository *repo, void odb_close(struct object_database *o) { struct odb_source *source; - for (source = o->sources; source; source = source->next) { - struct odb_source_files *files = odb_source_files_downcast(source); - packfile_store_close(files->packed); - } + for (source = o->sources; source; source = source->next) + odb_source_close(source); close_commit_graph(o); } |
