*: replace deprecated free_commit_list

Replace `free_commit_list` with `commit_list_free`. The former was deprecated in 9f18d089 (commit: rename `free_commit_list()` to conform to coding guidelines, 2026-01-15). This allows us to remove all the deprecated functions in the next commit: • `copy_commit_list` • `reverse_commit_list` • `free_commit_list` Acked-by: Patrick Steinhardt <ps@pks.im> Signed-off-by: Kristoffer Haugsbakk <code@khaugsbakk.name> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Kristoffer Haugsbakk committed May 28, 2026 at 09:00 UTC 7dd898a92ddc2318c3516c06fb6769c3e64216ed
3 files changed +5 -5
builtin/history.c
+2 -2
@@ -272,7 +272,7 @@ static int setup_revwalk(struct repository *repo,
272
273 commit_list_insert(original, &from_list);
274 ret = repo_is_descendant_of(repo, head, from_list);
275 - free_commit_list(from_list);
275 + commit_list_free(from_list);
276
277 if (ret < 0) {
278 ret = error(_("cannot determine descendance"));
@@ -649,7 +649,7 @@ out:
649 if (index_file.len)
650 unlink(index_file.buf);
651 strbuf_release(&index_file);
652 - free_commit_list(parents);
652 + commit_list_free(parents);
653 release_index(&index);
654 return ret;
655 }
replay.c
+1 -1
@@ -120,7 +120,7 @@ static struct commit *create_commit(struct repository *repo,
120 out:
121 repo_unuse_commit_buffer(repo, based_on, message);
122 free_commit_extra_headers(extra);
123 - free_commit_list(parents);
123 + commit_list_free(parents);
124 strbuf_release(&msg);
125 free(author);
126 return (struct commit *)obj;
upload-pack.c
+2 -2
@@ -886,7 +886,7 @@ static void deepen(struct upload_pack_data *data, int depth)
886 data->deepen_relative, depth,
887 SHALLOW, NOT_SHALLOW);
888 send_shallow(data, result);
889 - free_commit_list(result);
889 + commit_list_free(result);
890 }
891
892 send_unshallow(data);
@@ -900,7 +900,7 @@ static void deepen_by_rev_list(struct upload_pack_data *data,
900 disable_commit_graph(the_repository);
901 result = get_shallow_commits_by_rev_list(argv, SHALLOW, NOT_SHALLOW);
902 send_shallow(data, result);
903 - free_commit_list(result);
903 + commit_list_free(result);
904 send_unshallow(data);
905 }
906