]> gitweb.ps.run Git - ps-cgit/blobdiff - ui-log.c
git: update to v2.39.2
[ps-cgit] / ui-log.c
index 565929f3f046daaf8db1c89fc3d6928c23119ad0..311304ab80abd60fd957d5bf89a5d1a3d5e008d3 100644 (file)
--- a/ui-log.c
+++ b/ui-log.c
@@ -489,8 +489,7 @@ void cgit_print_log(const char *tip, int ofs, int cnt, char *grep, char *pattern
        for (i = 0; i < ofs && (commit = get_revision(&rev)) != NULL; /* nop */) {
                if (show_commit(commit, &rev))
                        i++;
        for (i = 0; i < ofs && (commit = get_revision(&rev)) != NULL; /* nop */) {
                if (show_commit(commit, &rev))
                        i++;
-               free_commit_buffer(the_repository->parsed_objects, commit);
-               free_commit_list(commit->parents);
+               release_commit_memory(the_repository->parsed_objects, commit);
                commit->parents = NULL;
        }
 
                commit->parents = NULL;
        }
 
@@ -511,8 +510,7 @@ void cgit_print_log(const char *tip, int ofs, int cnt, char *grep, char *pattern
                        i++;
                        print_commit(commit, &rev);
                }
                        i++;
                        print_commit(commit, &rev);
                }
-               free_commit_buffer(the_repository->parsed_objects, commit);
-               free_commit_list(commit->parents);
+               release_commit_memory(the_repository->parsed_objects, commit);
                commit->parents = NULL;
        }
        if (pager) {
                commit->parents = NULL;
        }
        if (pager) {