From 7a2e855d28d1984c1d60bd4606a4e345b975a69e Mon Sep 17 00:00:00 2001 From: Joris Vink Date: Wed, 26 Jun 2013 16:57:34 +0200 Subject: [PATCH] set tstamp to 0 in the correct location --- modules/example/src/example.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/example/src/example.c b/modules/example/src/example.c index dadb941..3fa90db 100644 --- a/modules/example/src/example.c +++ b/modules/example/src/example.c @@ -51,6 +51,7 @@ serve_style_css(struct http_request *req) char *date; time_t tstamp; + tstamp = 0; if (http_request_header_get(req, "if-modified-since", &date)) { tstamp = kore_date_to_time(date); free(date); @@ -58,7 +59,6 @@ serve_style_css(struct http_request *req) kore_debug("header was present with %ld", tstamp); } - tstamp = 0; if (tstamp != 0 && tstamp <= static_mtime_css_style) { ret = http_response(req, 304, NULL, 0); } else {