summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2020-03-05 18:43:04 (GMT)
committerJunio C Hamano <gitster@pobox.com>2020-03-05 18:43:04 (GMT)
commit5da7329e29db93a93099bfee2a81171392341ac8 (patch)
tree42e43ad5fe45b1359d3b0ce9d0203ea1bfe260d3
parent0108fc1b46e4ff2cdad9edd18c5c0d1b459d7a9d (diff)
parentd68ce906c7e1b2bb28a389b915cb63ddbae43365 (diff)
downloadgit-5da7329e29db93a93099bfee2a81171392341ac8.zip
git-5da7329e29db93a93099bfee2a81171392341ac8.tar.gz
git-5da7329e29db93a93099bfee2a81171392341ac8.tar.bz2
Merge branch 'rs/commit-graph-code-simplification'
Code simplfication. * rs/commit-graph-code-simplification: commit-graph: use progress title directly
-rw-r--r--commit-graph.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/commit-graph.c b/commit-graph.c
index 656dd64..f013a84 100644
--- a/commit-graph.c
+++ b/commit-graph.c
@@ -1657,19 +1657,15 @@ static void merge_commit_graphs(struct write_commit_graph_context *ctx)
{
struct commit_graph *g = ctx->r->objects->commit_graph;
uint32_t current_graph_number = ctx->num_commit_graphs_before;
- struct strbuf progress_title = STRBUF_INIT;
while (g && current_graph_number >= ctx->num_commit_graphs_after) {
current_graph_number--;
- if (ctx->report_progress) {
- strbuf_addstr(&progress_title, _("Merging commit-graph"));
- ctx->progress = start_delayed_progress(progress_title.buf, 0);
- }
+ if (ctx->report_progress)
+ ctx->progress = start_delayed_progress(_("Merging commit-graph"), 0);
merge_commit_graph(ctx, g);
stop_progress(&ctx->progress);
- strbuf_release(&progress_title);
g = g->base_graph;
}