Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/midx.c
diff options
context:
space:
mode:
authorTaylor Blau <me@ttaylorr.com>2022-09-20 04:55:56 +0300
committerJunio C Hamano <gitster@pobox.com>2022-09-21 20:21:47 +0300
commitb62ad5681f7ff08065d172f541ab2578d7b38e18 (patch)
tree402b3c4c6c614e232bf7d1137dd49e6b14e4f4b3 /midx.c
parent0a8e5614924abaac17008aea3cef2ee8fa25f26a (diff)
midx.c: avoid cruft packs with non-zero `repack --batch-size`
Apply similar treatment with respect to cruft packs as in a few commits ago to `repack` with a non-zero `--batch-size`. Since the case of a non-zero `--batch-size` is handled separately (in `fill_included_packs_batch()` instead of `fill_included_packs_all()`), a separate fix must be applied for this case. Signed-off-by: Taylor Blau <me@ttaylorr.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'midx.c')
-rw-r--r--midx.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/midx.c b/midx.c
index 273704caed..3a8dcfe98e 100644
--- a/midx.c
+++ b/midx.c
@@ -1946,6 +1946,8 @@ static int fill_included_packs_batch(struct repository *r,
continue;
if (!pack_kept_objects && p->pack_keep)
continue;
+ if (p->is_cruft)
+ continue;
if (open_pack_index(p) || !p->num_objects)
continue;