From: Martin Mares Date: Mon, 17 Jun 2013 19:52:15 +0000 (+0200) Subject: Let the caching flags mention conditional requests X-Git-Url: http://mj.ucw.cz/gitweb/?a=commitdiff_plain;h=b85f61a8a66f08b10dd1dcb77366cff974957d4d;p=netgrind.git Let the caching flags mention conditional requests --- diff --git a/README b/README index 71a02dd..5de2683 100644 --- a/README +++ b/README @@ -69,8 +69,9 @@ transaction ID Cache status codes: 1st char: request cacheing control . = none - N = don't cache + (first matching letter used) N = don't cache R = revalidate + c = conditional request (If-Modified-Since, If-Match) 2nd char: response cacheability . = not restricted (first matching letter used) N = don't cache diff --git a/netgrind/http.c b/netgrind/http.c index e9ca9c9..0a221c6 100644 --- a/netgrind/http.c +++ b/netgrind/http.c @@ -368,6 +368,8 @@ static void http_cache_report(struct http_state *s, char *buf) buf[0] = 'N'; else if (find_token(rq_cc, "max-age=0") || find_token(rq_cc, "must-revalidate")) buf[0] = 'R'; + else if (http_lookup_hdr(&s->req_headers, "If-Match:") || http_lookup_hdr(&s->req_headers, "If-Modified-Since:")) + buf[0] = 'c'; else buf[0] = '.';