comparison src/http/ngx_http_upstream.c @ 487:f2c6a7373274 NGINX_0_7_51

nginx 0.7.51 *) Feature: the "try_files" directive supports a response code in the fallback parameter. *) Feature: now any response code can be used in the "return" directive. *) Bugfix: the "error_page" directive made an external redirect without query string; the bug had appeared in 0.7.44. *) Bugfix: if servers listened on several defined explicitly addresses, then virtual servers might not work; the bug had appeared in 0.7.39.
author Igor Sysoev <http://sysoev.ru>
date Sun, 12 Apr 2009 00:00:00 +0400
parents 09f0ef15d544
children 549994537f15
comparison
equal deleted inserted replaced
486:ba2ea8c4d60f 487:f2c6a7373274
1943 } else { 1943 } else {
1944 u->cacheable = 0; 1944 u->cacheable = 0;
1945 } 1945 }
1946 } 1946 }
1947 1947
1948 ngx_log_debug1(NGX_LOG_DEBUG_HTTP, c->log, 0,
1949 "http cacheable: %d", u->cacheable);
1950
1948 #endif 1951 #endif
1949 1952
1950 p = u->pipe; 1953 p = u->pipe;
1951 1954
1952 p->output_filter = (ngx_event_pipe_output_filter_pt) ngx_http_output_filter; 1955 p->output_filter = (ngx_event_pipe_output_filter_pt) ngx_http_output_filter;
2744 u->pipe->temp_file->file.fd); 2747 u->pipe->temp_file->file.fd);
2745 } 2748 }
2746 2749
2747 #if (NGX_HTTP_CACHE) 2750 #if (NGX_HTTP_CACHE)
2748 2751
2749 if (r->cache) { 2752 if (u->cacheable) {
2750 time_t valid; 2753 time_t valid;
2751 2754
2752 ngx_log_debug1(NGX_LOG_DEBUG_HTTP, r->connection->log, 0, 2755 ngx_log_debug1(NGX_LOG_DEBUG_HTTP, r->connection->log, 0,
2753 "http upstream cache fd: %d", 2756 "http upstream cache fd: %d",
2754 r->cache->file.fd); 2757 r->cache->file.fd);
2766 ngx_http_file_cache_free(r, u->pipe->temp_file); 2769 ngx_http_file_cache_free(r, u->pipe->temp_file);
2767 } 2770 }
2768 2771
2769 #endif 2772 #endif
2770 2773
2771 if (u->header_sent && (rc == NGX_ERROR || rc >= NGX_HTTP_SPECIAL_RESPONSE)) 2774 if (u->header_sent
2775 && (rc == NGX_ERROR || rc >= NGX_HTTP_SPECIAL_RESPONSE))
2772 { 2776 {
2773 rc = 0; 2777 rc = 0;
2774 } 2778 }
2775 2779
2776 if (rc == NGX_DECLINED) { 2780 if (rc == NGX_DECLINED) {