Changes with Apache 2.3.13
+ *) mod_cache: When content is served stale, and there is no means to
+ revalidate the content using ETag or Last-Modified, and we have
+ mandated no stale-on-error behaviour, stand down and don't cache.
+ Saves a cache write that will never be read.
+ [Graham Leggett]
+
*) mod_reqtimeout: Fix a timed out connection going into the keep-alive
state after a timeout when discarding a request body. PR 51103.
[Stefan Fritsch]
reason = apr_pstrcat(p, "Broken expires header: ", exps, NULL);
}
else if (!dconf->store_expired && exp != APR_DATE_BAD
- && exp < r->request_time)
- {
+ && exp < r->request_time) {
/* if a Expires header is in the past, don't cache it */
reason = "Expires header already expired; not cacheable";
}
+ else if (!dconf->store_expired && (control.must_revalidate
+ || control.proxy_revalidate) && (!control.s_maxage_value
+ || (!control.s_maxage && !control.max_age_value)) && lastmod
+ == NULL && etag == NULL) {
+ /* if we're already stale, but can never revalidate, don't cache it */
+ reason
+ = "s-maxage or max-age zero and no Last-Modified or Etag; not cacheable";
+ }
else if (!conf->ignorequerystring && r->parsed_uri.query && exps == NULL
&& !control.max_age && !control.s_maxage) {
/* if a query string is present but no explicit expiration time,