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:44 +0300
committerJunio C Hamano <gitster@pobox.com>2022-04-14 09:56:09 +0300
commitf0cb6b8053eb9146e9d5255b6b0473d020c6e8bd (patch)
tree884ec63039b04bbcd23c88cc23385f74c47e743c /diff-lib.c
parentbf1b32d0991cfead7e5604897d0866b789bf602e (diff)
revisions API users: use release_revisions() for "prune_data" users
Use release_revisions() for users of "struct rev_list" that reach into the "struct rev_info" and clear the "prune_data" already. In a subsequent commit we'll teach release_revisions() to clear this itself, but in the meantime let's invoke release_revisions() here to clear anything else we may have missed, and for reasons of having consistent boilerplate. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'diff-lib.c')
-rw-r--r--diff-lib.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/diff-lib.c b/diff-lib.c
index d6800274bd..0f16281253 100644
--- a/diff-lib.c
+++ b/diff-lib.c
@@ -642,6 +642,7 @@ int do_diff_cache(const struct object_id *tree_oid, struct diff_options *opt)
if (diff_cache(&revs, tree_oid, NULL, 1))
exit(128);
clear_pathspec(&revs.prune_data);
+ release_revisions(&revs);
return 0;
}