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
diff options
context:
space:
mode:
authorÆvar Arnfjörð Bjarmason <avarab@gmail.com>2022-04-13 23:01:31 +0300
committerJunio C Hamano <gitster@pobox.com>2022-04-14 09:56:08 +0300
commit4b59b2db97af0b40fc2688069c3a91ba28f8883d (patch)
treedf591eea27df8e73a2b5d41c44c35ac7b86ac7ac /builtin/blame.c
parentb925fcf12951dba85313afd08c6154d8d978b03e (diff)
blame: use "goto cleanup" for cleanup_scoreboard()
Amend a freeing pattern added in 0906ac2b54b (blame: use changed-path Bloom filters, 2020-04-16) to use a "goto cleanup", so that we can be sure that we call cleanup_scoreboard(). Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin/blame.c')
-rw-r--r--builtin/blame.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/builtin/blame.c b/builtin/blame.c
index 8d15b68afc..885b381ab8 100644
--- a/builtin/blame.c
+++ b/builtin/blame.c
@@ -1167,7 +1167,7 @@ parse_done:
if (!incremental)
setup_pager();
else
- return 0;
+ goto cleanup;
blame_sort_final(&sb);
@@ -1201,6 +1201,7 @@ parse_done:
printf("num commits: %d\n", sb.num_commits);
}
+cleanup:
cleanup_scoreboard(&sb);
return 0;
}