diff options
author | Ævar Arnfjörð Bjarmason <avarab@gmail.com> | 2021-10-20 20:27:20 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2021-10-20 11:36:13 -0700 |
commit | e5fb028688f5811bd835c0bc47f8d7a379a0d152 (patch) | |
tree | a9e8e75d8139818d8f39240d5ef5bb9ce27ac179 /builtin/for-each-ref.c | |
parent | 37766b61cdb3e12709febcd2f9dbee2b90e62969 (diff) | |
download | git-e5fb028688f5811bd835c0bc47f8d7a379a0d152.tar.gz |
ref-filter API user: add and use a ref_sorting_release()
Add a ref_sorting_release() and use it for some of the current API
users, the ref_sorting_default() function and its siblings will do a
malloc() which wasn't being free'd previously.
Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin/for-each-ref.c')
-rw-r--r-- | builtin/for-each-ref.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/builtin/for-each-ref.c b/builtin/for-each-ref.c index 642b4b888f..16a2c7d57c 100644 --- a/builtin/for-each-ref.c +++ b/builtin/for-each-ref.c @@ -96,6 +96,6 @@ int cmd_for_each_ref(int argc, const char **argv, const char *prefix) ref_array_clear(&array); free_commit_list(filter.with_commit); free_commit_list(filter.no_commit); - UNLEAK(sorting); + ref_sorting_release(sorting); return 0; } |