From c8d012d425137f36ee0b509ce1e95f339cfe5cbc Mon Sep 17 00:00:00 2001 From: Maxim Dounin Date: Sun, 5 Feb 2012 19:23:44 +0000 Subject: Merge of r4402: Fixed proxy_cache_use_stale in "no live upstreams" case. --- src/http/modules/ngx_http_scgi_module.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/http/modules/ngx_http_scgi_module.c') diff --git a/src/http/modules/ngx_http_scgi_module.c b/src/http/modules/ngx_http_scgi_module.c index e6c3afaed..103601f45 100644 --- a/src/http/modules/ngx_http_scgi_module.c +++ b/src/http/modules/ngx_http_scgi_module.c @@ -1237,6 +1237,10 @@ ngx_http_scgi_merge_loc_conf(ngx_conf_t *cf, void *parent, void *child) |NGX_HTTP_UPSTREAM_FT_OFF; } + if (conf->upstream.cache_use_stale & NGX_HTTP_UPSTREAM_FT_ERROR) { + conf->upstream.cache_use_stale |= NGX_HTTP_UPSTREAM_FT_NOLIVE; + } + if (conf->upstream.cache_methods == 0) { conf->upstream.cache_methods = prev->upstream.cache_methods; } -- cgit