call init_pack_revindex() lazily
This makes life much easier for next patch, as well as being more efficient when the revindex is actually not used. Signed-off-by: Nicolas Pitre <nico@cam.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:

committed by
Junio C Hamano

parent
6b516d984b
commit
1f5c74f6cf
@ -1148,8 +1148,6 @@ static void get_object_details(void)
|
||||
sorted_by_offset[i] = objects + i;
|
||||
qsort(sorted_by_offset, nr_objects, sizeof(*sorted_by_offset), pack_offset_sort);
|
||||
|
||||
init_pack_revindex();
|
||||
|
||||
for (i = 0; i < nr_objects; i++)
|
||||
check_object(sorted_by_offset[i]);
|
||||
|
||||
|
Reference in New Issue
Block a user