diff options
| author | Maxim Dounin <mdounin@mdounin.ru> | 2014-01-04 03:32:10 +0400 |
|---|---|---|
| committer | Maxim Dounin <mdounin@mdounin.ru> | 2014-01-04 03:32:10 +0400 |
| commit | def37d254aa4f9523b7bf82b1d26530e0b216842 (patch) | |
| tree | 947deb6d667f108b97f0eba9ac29d8655a1c698e /src | |
| parent | 1029607ac9eebb78c9f1b75f5b62002d7f4789e7 (diff) | |
| download | nginx-def37d254aa4f9523b7bf82b1d26530e0b216842.tar.gz nginx-def37d254aa4f9523b7bf82b1d26530e0b216842.tar.bz2 | |
Upstream: Cache-Control preferred over Expires.
Not really a strict check (as X-Accel-Expires might be ignored or
contain invalid value), but quite simple to implement and better
than what we have now.
Diffstat (limited to 'src')
| -rw-r--r-- | src/http/ngx_http_upstream.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/http/ngx_http_upstream.c b/src/http/ngx_http_upstream.c index 8c436b3ca..b6504d325 100644 --- a/src/http/ngx_http_upstream.c +++ b/src/http/ngx_http_upstream.c @@ -3656,7 +3656,7 @@ ngx_http_upstream_process_cache_control(ngx_http_request_t *r, return NGX_OK; } - if (r->cache->valid_sec != 0) { + if (r->cache->valid_sec != 0 && u->headers_in.x_accel_expires != NULL) { return NGX_OK; } |
