aboutsummaryrefslogtreecommitdiff
path: root/submodule.c
diff options
context:
space:
mode:
authorPatrick Steinhardt <ps@pks.im>2026-01-15 10:35:34 +0100
committerJunio C Hamano <gitster@pobox.com>2026-01-15 05:32:31 -0800
commit9f18d089c51fba2776fe1fece877a359c47417f7 (patch)
treee51d5ec9b79ebda7f0b928d7c71f4d36adad4a81 /submodule.c
parenta468f3cefab32eed7d9a12bd6b93719d38ec67a6 (diff)
downloadgit-9f18d089c51fba2776fe1fece877a359c47417f7.tar.xz
commit: rename `free_commit_list()` to conform to coding guidelines
Our coding guidelines say that: Functions that operate on `struct S` are named `S_<verb>()` and should generally receive a pointer to `struct S` as first parameter. While most of the functions related to `struct commit_list` already follow that naming schema, `free_commit_list()` doesn't. Rename the function to address this and adjust all of its callers. Add a compatibility wrapper for the old function name to ease the transition and avoid any semantic conflicts with in-flight patch series. This wrapper will be removed once Git 2.53 has been released. Signed-off-by: Patrick Steinhardt <ps@pks.im> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'submodule.c')
-rw-r--r--submodule.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/submodule.c b/submodule.c
index 40a5c6fb9d..85e9586e66 100644
--- a/submodule.c
+++ b/submodule.c
@@ -639,7 +639,7 @@ void show_submodule_diff_summary(struct diff_options *o, const char *path,
print_submodule_diff_summary(sub, &rev, o);
out:
- free_commit_list(merge_bases);
+ commit_list_free(merge_bases);
release_revisions(&rev);
clear_commit_marks(left, ~0);
clear_commit_marks(right, ~0);
@@ -729,7 +729,7 @@ void show_submodule_inline_diff(struct diff_options *o, const char *path,
done:
strbuf_release(&sb);
- free_commit_list(merge_bases);
+ commit_list_free(merge_bases);
if (left)
clear_commit_marks(left, ~0);
if (right)