summaryrefslogtreecommitdiff
path: root/pack-bitmap.c
diff options
context:
space:
mode:
authorTaylor Blau <me@ttaylorr.com>2021-01-13 22:24:27 (GMT)
committerJunio C Hamano <gitster@pobox.com>2021-01-14 05:53:46 (GMT)
commit78232bf65d59601fad99b4f45a90effaf0ac1204 (patch)
tree8b232d1443770239d29f99de82c9d547bf089ecd /pack-bitmap.c
parent011f3fd5cdacc69e2ba2adf998656adcd2045a0f (diff)
downloadgit-78232bf65d59601fad99b4f45a90effaf0ac1204.zip
git-78232bf65d59601fad99b4f45a90effaf0ac1204.tar.gz
git-78232bf65d59601fad99b4f45a90effaf0ac1204.tar.bz2
rebuild_existing_bitmaps(): convert to new revindex API
Remove another instance of looking at the revindex directly by instead calling 'pack_pos_to_index()'. Unlike other patches, this caller only cares about the index position of each object in the loop. Signed-off-by: Taylor Blau <me@ttaylorr.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'pack-bitmap.c')
-rw-r--r--pack-bitmap.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/pack-bitmap.c b/pack-bitmap.c
index 1fdf7ce..60fe20f 100644
--- a/pack-bitmap.c
+++ b/pack-bitmap.c
@@ -1392,11 +1392,10 @@ uint32_t *create_bitmap_mapping(struct bitmap_index *bitmap_git,
for (i = 0; i < num_objects; ++i) {
struct object_id oid;
- struct revindex_entry *entry;
struct object_entry *oe;
- entry = &bitmap_git->pack->revindex[i];
- nth_packed_object_id(&oid, bitmap_git->pack, entry->nr);
+ nth_packed_object_id(&oid, bitmap_git->pack,
+ pack_pos_to_index(bitmap_git->pack, i));
oe = packlist_find(mapping, &oid);
if (oe)