]> gitweb.ps.run Git - ps-cgit/blobdiff - cgit.c
fix building with clang
[ps-cgit] / cgit.c
diff --git a/cgit.c b/cgit.c
index 75d9926539fb78f0976a3ce7ea34e3b6176bd8fb..e61629237cac22d9de48cf3316873cd7d0f586d4 100644 (file)
--- a/cgit.c
+++ b/cgit.c
@@ -143,6 +143,8 @@ static void config_cb(const char *name, const char *value)
                ctx.cfg.root_readme = xstrdup(value);
        else if (!strcmp(name, "css"))
                string_list_append(&ctx.cfg.css, xstrdup(value));
+       else if (!strcmp(name, "js"))
+               string_list_append(&ctx.cfg.js, xstrdup(value));
        else if (!strcmp(name, "favicon"))
                ctx.cfg.favicon = xstrdup(value);
        else if (!strcmp(name, "footer"))
@@ -629,7 +631,7 @@ static int prepare_repo_cmd(int nongit)
                return 1;
        }
 
-       if (get_oid(ctx.qry.head, &oid)) {
+       if (repo_get_oid(the_repository, ctx.qry.head, &oid)) {
                char *old_head = ctx.qry.head;
                ctx.qry.head = xstrdup(ctx.repo->defbranch);
                cgit_print_error_page(404, "Not found",