]> git.cameronkatri.com Git - cgit.git/blobdiff - ui-refs.c
Hosted on HTTPS now
[cgit.git] / ui-refs.c
index ac8a6d446e14765afabfcffe0f41f6fb32256b68..5b4530e5410fd159534e03051ce86471c0992bf3 100644 (file)
--- a/ui-refs.c
+++ b/ui-refs.c
@@ -63,7 +63,7 @@ static int print_branch(struct refinfo *ref)
                return 1;
        html("<tr><td>");
        cgit_log_link(name, NULL, NULL, name, NULL, NULL, 0, NULL, NULL,
-                     ctx.qry.showmsg);
+                     ctx.qry.showmsg, 0);
        html("</td><td>");
 
        if (ref->object->type == OBJ_COMMIT) {
@@ -73,7 +73,7 @@ static int print_branch(struct refinfo *ref)
                html_txt(info->author);
                cgit_close_filter(ctx.repo->email_filter);
                html("</td><td colspan='2'>");
-               cgit_print_age(info->commit->date, -1, NULL);
+               cgit_print_age(info->committer_date, info->committer_tz, -1);
        } else {
                html("</td><td></td><td>");
                cgit_object_link(ref->object);
@@ -82,7 +82,7 @@ static int print_branch(struct refinfo *ref)
        return 0;
 }
 
-static void print_tag_header()
+static void print_tag_header(void)
 {
        html("<tr class='nohover'><th class='left'>Tag</th>"
             "<th class='left'>Download</th>"
@@ -135,7 +135,7 @@ static int print_tag(struct refinfo *ref)
                tag = (struct tag *)obj;
                obj = tag->tagged;
                info = ref->tag;
-               if (!tag || !info)
+               if (!info)
                        return 1;
        }
 
@@ -161,9 +161,9 @@ static int print_tag(struct refinfo *ref)
        html("</td><td colspan='2'>");
        if (info) {
                if (info->tagger_date > 0)
-                       cgit_print_age(info->tagger_date, -1, NULL);
+                       cgit_print_age(info->tagger_date, info->tagger_tz, -1);
        } else if (ref->object->type == OBJ_COMMIT) {
-               cgit_print_age(ref->commit->commit->date, -1, NULL);
+               cgit_print_age(ref->commit->commit->date, 0, -1);
        }
        html("</td></tr>\n");
 
@@ -234,9 +234,9 @@ void cgit_print_tags(int maxcount)
        cgit_free_reflist_inner(&list);
 }
 
-void cgit_print_refs()
+void cgit_print_refs(void)
 {
-
+       cgit_print_layout_start();
        html("<table class='list nowrap'>");
 
        if (ctx.qry.path && starts_with(ctx.qry.path, "heads"))
@@ -249,4 +249,5 @@ void cgit_print_refs()
                cgit_print_tags(0);
        }
        html("</table>");
+       cgit_print_layout_end();
 }