cgit

commit a6a11125283cd159bbd22e4e3c619bccad1162df

Author: Lars Hjemli <larsh@hal-2004.(none)>

Use TTL-settings even in nocache mode

In nocace mode an uninitialized ttl-setting was used to generate http-Expires
header. Fix it.

Signed-off-by: Lars Hjemli <larsh@hal-2004.(none)>

 cgit.c | 1 +


diff --git a/cgit.c b/cgit.c
index fba97d7277ffc881136152c2a009533ecede07a1..5dcba768f0baefe15196053799c0d53b498b126e 100644
--- a/cgit.c
+++ b/cgit.c
@@ -153,6 +153,7 @@ 	cgit_parse_args(argc, argv);
 	cgit_parse_query(cgit_querystring, cgit_querystring_cb);
 
 	if (cgit_nocache) {
+		cache_prepare(&item);
 		item.fd = STDOUT_FILENO;
 		cgit_fill_cache(&item);
 	} else {