Skip to content

Commit f77dbf0

Browse files
ttaylorrgitster
authored andcommitted
pack-bitmap.c: teach show_objects_for_type() about incremental MIDXs
Since we may ask for a pack_id that is in an earlier MIDX layer relative to the one corresponding to our bitmap, use nth_midxed_pack() instead of accessing the ->packs array directly. Signed-off-by: Taylor Blau <[email protected]> Acked-by: Elijah Newren <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent ae61324 commit f77dbf0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pack-bitmap.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1636,7 +1636,7 @@ static void show_objects_for_type(
16361636
nth_midxed_object_oid(&oid, m, index_pos);
16371637

16381638
pack_id = nth_midxed_pack_int_id(m, index_pos);
1639-
pack = bitmap_git->midx->packs[pack_id];
1639+
pack = nth_midxed_pack(bitmap_git->midx, pack_id);
16401640
} else {
16411641
index_pos = pack_pos_to_index(bitmap_git->pack, pos + offset);
16421642
ofs = pack_pos_to_offset(bitmap_git->pack, pos + offset);

0 commit comments

Comments
 (0)