]> git.cameronkatri.com Git - cgit.git/blobdiff - ui-shared.c
Fix segmentation fault in empty repository
[cgit.git] / ui-shared.c
index 85c20964b1b1f8778022c4aa281caf187fcc738b..3e9282f35c0e032251b26ab00bd7f35e3bb7aee0 100644 (file)
@@ -619,7 +619,7 @@ void cgit_print_docstart(struct cgit_context *ctx)
                html_attr(ctx->cfg.favicon);
                html("'/>\n");
        }
-       if (host && ctx->repo) {
+       if (host && ctx->repo && ctx->qry.head) {
                html("<link rel='alternate' title='Atom feed' href='");
                html(cgit_httpscheme());
                html_attr(cgit_hosturl());