From 814d69e9c3f9349f211ea3ff04abb5d14c28a7ea Mon Sep 17 00:00:00 2001 From: Bryce Kwon Date: Sat, 31 Oct 2026 14:55:45 -0700 Subject: Free the revision walks' arguments and state --- source/ui-log.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'source/ui-log.c') diff --git a/source/ui-log.c b/source/ui-log.c index 2211aa0..ef52951 100644 --- a/source/ui-log.c +++ b/source/ui-log.c @@ -453,7 +453,7 @@ int cgit_log_columns(int graph) void cgit_print_log(const char *tip, int ofs, int cnt, const char *grep, const char *pattern, const char *path, int pager, int commit_graph, int commit_sort, int table_columns) { - struct rev_info rev; + struct rev_info rev = REV_INFO_INIT; struct commit *commit; struct strvec rev_argv = STRVEC_INIT; struct string_list tokens = STRING_LIST_INIT_DUP; @@ -528,7 +528,7 @@ void cgit_print_log(const char *tip, int ofs, int cnt, const char *grep, const c // The author and committer searches then match the mapped idents. rev.mailmap = cgit_mailmap(); rev.ignore_missing = 1; - setup_revisions(rev_argv.nr, rev_argv.v, &rev, NULL); + setup_revisions_from_strvec(&rev_argv, &rev, NULL); load_ref_decorations(NULL, DECORATE_FULL_REFS); rev.show_decorations = 1; @@ -613,6 +613,7 @@ void cgit_print_log(const char *tip, int ofs, int cnt, const char *grep, const c } out: + release_revisions(&rev); if (must_free_tip) free((char *)tip); strvec_clear(&rev_argv); -- cgit