diff options
| author | Igor Sysoev <igor@sysoev.ru> | 2006-10-10 16:10:45 +0000 |
|---|---|---|
| committer | Jonathan Kolb <jon@b0g.us> | 2006-10-10 16:10:45 +0000 |
| commit | 3c7373afd0117d9196e264d7a6a732c703d62c1c (patch) | |
| tree | b74a138028fe7c94dde99b199318a5c8ee43b337 /src/http/ngx_http_upstream.c | |
| parent | 3d565750a763f163a008160380b44853e146c511 (diff) | |
| download | nginx-3c7373afd0117d9196e264d7a6a732c703d62c1c.tar.gz | |
Changes with nginx 0.4.7 10 Oct 2006v0.4.7
*) Feature: the ngx_http_flv_module.
*) Feature: the $request_body_file variable.
*) Feature: the "charset" and "source_charset" directives support the
variables.
*) Bugfix: if before an "include" SSI command with an "wait" parameter
were yet another "include" SSI command, then the "wait" parameter
might not work.
*) Bugfix: if the "proxy_buffering off" directive was used or while
working with memcached the connections might not be closed on
timeout.
*) Bugfix: nginx did not run on 64-bit platforms except amd64, sparc64,
and ppc64.
Diffstat (limited to 'src/http/ngx_http_upstream.c')
| -rw-r--r-- | src/http/ngx_http_upstream.c | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/src/http/ngx_http_upstream.c b/src/http/ngx_http_upstream.c index 2cdfdc8ba..e4a4d4058 100644 --- a/src/http/ngx_http_upstream.c +++ b/src/http/ngx_http_upstream.c @@ -1137,6 +1137,7 @@ ngx_http_upstream_process_header(ngx_event_t *rev) umcf = ngx_http_get_module_main_conf(r, ngx_http_upstream_module); if (r->upstream->headers_in.x_accel_redirect) { + ngx_http_upstream_finalize_request(r, u, NGX_DECLINED); part = &r->upstream->headers_in.headers.part; @@ -1159,8 +1160,8 @@ ngx_http_upstream_process_header(ngx_event_t *rev) if (hh && hh->redirect) { if (hh->copy_handler(r, &h[i], hh->conf) != NGX_OK) { - ngx_http_upstream_finalize_request(r, u, - NGX_HTTP_INTERNAL_SERVER_ERROR); + ngx_http_finalize_request(r, + NGX_HTTP_INTERNAL_SERVER_ERROR); return; } } @@ -1172,7 +1173,7 @@ ngx_http_upstream_process_header(ngx_event_t *rev) flags = 0; if (ngx_http_parse_unsafe_uri(r, uri, &args, &flags) != NGX_OK) { - ngx_http_upstream_finalize_request(r, u, NGX_HTTP_NOT_FOUND); + ngx_http_finalize_request(r, NGX_HTTP_NOT_FOUND); return; } @@ -1500,6 +1501,8 @@ ngx_http_upstream_process_non_buffered_body(ngx_event_t *ev) ngx_http_core_loc_conf_t *clcf; c = ev->data; + r = c->data; + u = r->upstream; if (ev->write) { ngx_log_debug0(NGX_LOG_DEBUG_HTTP, c->log, 0, @@ -1520,10 +1523,11 @@ ngx_http_upstream_process_non_buffered_body(ngx_event_t *ev) } else { ngx_connection_error(c, NGX_ETIMEDOUT, "upstream timed out"); } + + ngx_http_upstream_finalize_request(r, u, 0); + return; } - r = c->data; - u = r->upstream; client = r->connection; b = &u->buffer; @@ -2941,7 +2945,7 @@ ngx_http_upstream_init_main_conf(ngx_conf_t *cf, void *conf) hash.hash = &umcf->headers_in_hash; hash.key = ngx_hash_key_lc; hash.max_size = 512; - hash.bucket_size = ngx_cacheline_size; + hash.bucket_size = ngx_align(64, ngx_cacheline_size); hash.name = "upstream_headers_in_hash"; hash.pool = cf->pool; hash.temp_pool = NULL; |
