From a3a9f7288306802a80693fa0aa8213b65d932479 Mon Sep 17 00:00:00 2001 From: Bryce Kwon Date: Wed, 4 Nov 2026 20:33:08 -1000 Subject: Leave the scan uncached with a negative cache-size The page cache counts a cache-size of 0 or less as off, but scan-path cached its list for any value other than 0, so a negative one still wrote a list into cache-root. --- source/cgit.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source/cgit.c') diff --git a/source/cgit.c b/source/cgit.c index dc483ee..81f2b14 100644 --- a/source/cgit.c +++ b/source/cgit.c @@ -698,7 +698,7 @@ static void apply_config(const char *name, const char *value) else if (!strcmp(name, "project-list")) ctx.cfg.project_list = cgit_strdup_first_line(cgit_expand_macros(value)); else if (!strcmp(name, "scan-path")) { - if (ctx.cfg.cache_size) + if (ctx.cfg.cache_size > 0) process_cached_repolist(cgit_expand_macros(value)); else scan_tree(cgit_expand_macros(value)); -- cgit 2.12.1