Vladimir Litovka wrote:
> Why there are documents in cache, which has 'Pragma: no-cache' header?
'Pragma: no-cache' is only defined for requests, not responses.
Here is a short code segment that adds Pragma: no-cache parsing on
responses, but it should really be solved at the HTTP server by sending
proper Expires: and/or Cache-Control: headers.
http.c:httpParseReplyHeader()
...
} else if (!strncasecmp(t, "Pragma:", 7)) {
for (t += 7; isspace(*t); t++);
if (!strncasecmp(t, "no-cache", 8)) {
EBIT_SET(reply->cache_control, SCC_NOCACHE);
ReplyHeaderStats.cc[SCC_NOCACHE]++;
}
} else if (!strncasecmp(t, "Cache-Control:", 14)) {
...
I's left as a excersise to the reader how to add this piece of code at
the right place.
--- Henrik Nordström Sparetime Squid HackerReceived on Thu Apr 30 1998 - 15:00:29 MDT
This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:39:59 MST