]> git.99rst.org Git - git.git/commit
midx: refactor interfaces to work on "packed" source
authorPatrick Steinhardt <redacted>
Wed, 17 Jun 2026 06:39:59 +0000 (08:39 +0200)
committerJunio C Hamano <redacted>
Wed, 17 Jun 2026 12:00:01 +0000 (05:00 -0700)
commit7fa8c61afe29bfb82066c81a82ed6393f34dd704
treef0fe2983438ecb05984b9e8615990e734c77f5b7
parentf236b0c38d11b97930608384eaddd210f74fc7ab
midx: refactor interfaces to work on "packed" source

Our interfaces used to interact with MIDXs all work on top of the
generic `struct odb_source`. This doesn't make much sense though: a MIDX
is strictly tied to the "packed" source, so passing in a generic source
gives the false sense that it may also work with a different type of
source.

Fix this conceptual weirdness and instead require the caller to pass in
a "packed" source explicitly. This also makes the next commit easier to
implement, where we drop the pointer to the "files" source in the
"packed" source.

Signed-off-by: Patrick Steinhardt <redacted>
Signed-off-by: Junio C Hamano <redacted>
13 files changed:
builtin/multi-pack-index.c
builtin/pack-objects.c
builtin/repack.c
midx-write.c
midx.c
midx.h
odb/source-packed.c
pack-bitmap.c
pack-revindex.c
repack-geometry.c
repack-midx.c
repack.c
t/helper/test-read-midx.c
git clone https://git.99rst.org/PROJECT