From 689a8e80dd4f7b3a20be88146bdea833c7759603 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=86var=20Arnfj=C3=B6r=C3=B0=20Bjarmason?= Date: Wed, 13 Apr 2022 22:01:50 +0200 Subject: revisions API: have release_revisions() release "prune_data" MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Extend the the release_revisions() function so that it frees the "prune_data" in the "struct rev_info". This means that any code that calls "release_revisions()" already can get rid of adjacent calls to clear_pathspec(). Signed-off-by: Ævar Arnfjörð Bjarmason Signed-off-by: Junio C Hamano --- add-interactive.c | 2 -- 1 file changed, 2 deletions(-) (limited to 'add-interactive.c') diff --git a/add-interactive.c b/add-interactive.c index 54cdfc8201..6047e8f648 100644 --- a/add-interactive.c +++ b/add-interactive.c @@ -568,8 +568,6 @@ static int get_modified_files(struct repository *r, run_diff_files(&rev, 0); } - if (ps) - clear_pathspec(&rev.prune_data); release_revisions(&rev); } hashmap_clear_and_free(&s.file_map, struct pathname_entry, ent); -- cgit v1.2.3