]> git.cameronkatri.com Git - cgit.git/blobdiff - scan-tree.c
ui-summary: Pass filename to about-filter
[cgit.git] / scan-tree.c
index beb584b5952eb9407e90fc8c580ffffdb5dc5676..a1ec8fb7ac73cbc4416245087390849d199f822c 100644 (file)
@@ -113,6 +113,8 @@ static void add_repo(const char *base, struct strbuf *path, repo_config_fn fn)
 
        if (!strcmp(rel.buf + rel.len - 5, "/.git"))
                strbuf_setlen(&rel, rel.len - 5);
+       else if (rel.len && rel.buf[rel.len - 1] == '/')
+               strbuf_setlen(&rel, rel.len - 1);
 
        repo = cgit_add_repo(rel.buf);
        config_fn = fn;