]> git.ipfire.org Git - thirdparty/git.git/commit
midx-write.c: extract inner loop from fill_packs_from_midx()
authorTaylor Blau <me@ttaylorr.com>
Wed, 28 May 2025 22:59:06 +0000 (18:59 -0400)
committerJunio C Hamano <gitster@pobox.com>
Thu, 29 May 2025 19:53:47 +0000 (12:53 -0700)
commit5dff093ec0763cc3bcc083c9ebd04e4e119f086c
tree9f7b2211cd07535601380e21568cc42ac53dc5b4
parent76ec9c23615e11ffd58a32a436be45f0223c1168
midx-write.c: extract inner loop from fill_packs_from_midx()

The function fill_packs_from_midx() does relatively little, but ends up
in a doubly-nested loop because we're enumerating each pack within each
layer of the incremental MIDX chain.

Let's de-dent the inner loop of fill_packs_from_midx() by extracting its
contents into a separate function, and calling that.

Signed-off-by: Taylor Blau <me@ttaylorr.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
midx-write.c