]> gitweb.ps.run Git - ps-cgit/blobdiff - cgit.c
Clear the whole context
[ps-cgit] / cgit.c
diff --git a/cgit.c b/cgit.c
index 6bb712de0d3d6548fa34174fbb2d2cf61c5078fc..6c7e8111c4cf31456983fe9f946cd5eb8410c3c8 100644 (file)
--- a/cgit.c
+++ b/cgit.c
@@ -248,7 +248,7 @@ char *xstrdupn(const char *str)
 
 static void prepare_context(struct cgit_context *ctx)
 {
-       memset(ctx, 0, sizeof(ctx));
+       memset(ctx, 0, sizeof(*ctx));
        ctx->cfg.agefile = "info/web/last-modified";
        ctx->cfg.nocache = 0;
        ctx->cfg.cache_size = 0;