]> gitweb.ps.run Git - ps-cgit/blobdiff - ui-log.c
ui-shared: redirect should not exit early for cache
[ps-cgit] / ui-log.c
index 45732550bd7dc68e768862a5cb6c4f2bd03ba660..0a3938bf97c581b92e5ba0576d8232fd78c32a3a 100644 (file)
--- a/ui-log.c
+++ b/ui-log.c
@@ -141,7 +141,9 @@ static int show_commit(struct commit *commit, struct rev_info *revs)
 
        /* When we get here we have precisely one parent. */
        parent = parents->item;
-       parse_commit(parent);
+       /* If we can't parse the commit, let print_commit() report an error. */
+       if (parse_commit(parent))
+               return 1;
 
        files = 0;
        add_lines = 0;
@@ -202,7 +204,7 @@ static void print_commit(struct commit *commit, struct rev_info *revs)
        }
        else {
                html("<td>");
-               cgit_print_age(commit->date, TM_WEEK * 2, FMT_SHORTDATE);
+               cgit_print_age(info->committer_date, info->committer_tz, TM_WEEK * 2);
                html("</td>");
        }
 
@@ -242,7 +244,7 @@ static void print_commit(struct commit *commit, struct rev_info *revs)
 
        if (revs->graph) {
                html("</td><td>");
-               cgit_print_age(commit->date, TM_WEEK * 2, FMT_SHORTDATE);
+               cgit_print_age(info->committer_date, info->committer_tz, TM_WEEK * 2);
        }
 
        if (!lines_counted && (ctx.repo->enable_log_filecount ||