]> gitweb.ps.run Git - ps-cgit/blobdiff - shared.c
shared.c: initialize cgit_repo structs properly
[ps-cgit] / shared.c
index 9475581b2c4a20d73b639223156b8a7afbd5b5ca..d7b2d5a9efe777acc8140ae9401b9c9d17a5fd79 100644 (file)
--- a/shared.c
+++ b/shared.c
@@ -48,6 +48,7 @@ struct cgit_repo *cgit_add_repo(const char *url)
        }
 
        ret = &cgit_repolist.repos[cgit_repolist.count-1];
+       memset(ret, 0, sizeof(struct cgit_repo));
        ret->url = trim_end(url, '/');
        ret->name = ret->url;
        ret->path = NULL;