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:
authorDerrick Stolee <dstolee@microsoft.com>2021-02-18 17:07:32 +0300
committerJunio C Hamano <gitster@pobox.com>2021-02-19 00:38:16 +0300
commitc1442410d869cd5fb2c0dd79aa1a7c152b99b0f9 (patch)
treea44c8581e44fb68920b82258a7234a460ca9a560 /midx.c
parent0ccd713cb6c4dafd36bdf85384becbb9b38504ba (diff)
midx: drop chunk progress during write
Most expensive operations in write_midx_internal() use the context struct's progress member, and these indicate the process of the expensive operations within the chunk writing methods. However, there is a competing progress struct that counts the progress over all chunks. This is not very helpful compared to the others, so drop it. This also reduces our barriers to combining the chunk writing code with chunk-format.c. Signed-off-by: Derrick Stolee <dstolee@microsoft.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'midx.c')
-rw-r--r--midx.c7
1 files changed, 0 insertions, 7 deletions
diff --git a/midx.c b/midx.c
index c92a6c47be..4f4aa351e6 100644
--- a/midx.c
+++ b/midx.c
@@ -808,7 +808,6 @@ static int write_midx_internal(const char *object_dir, struct multi_pack_index *
uint64_t header_size = 0;
uint32_t chunk_ids[MIDX_MAX_CHUNKS + 1];
uint64_t chunk_offsets[MIDX_MAX_CHUNKS + 1];
- struct progress *progress = NULL;
int pack_name_concat_len = 0;
int dropped_packs = 0;
int result = 0;
@@ -976,9 +975,6 @@ static int write_midx_internal(const char *object_dir, struct multi_pack_index *
hashwrite_be64(f, chunk_offsets[i]);
}
- if (flags & MIDX_PROGRESS)
- progress = start_delayed_progress(_("Writing chunks to multi-pack-index"),
- num_chunks);
for (i = 0; i < num_chunks; i++) {
if (f->total + f->offset != chunk_offsets[i])
BUG("incorrect chunk offset (%"PRIu64" != %"PRIu64") for chunk id %"PRIx32,
@@ -1011,10 +1007,7 @@ static int write_midx_internal(const char *object_dir, struct multi_pack_index *
BUG("trying to write unknown chunk id %"PRIx32,
chunk_ids[i]);
}
-
- display_progress(progress, i + 1);
}
- stop_progress(&progress);
if (hashfile_total(f) != chunk_offsets[num_chunks])
BUG("incorrect final offset %"PRIu64" != %"PRIu64,