# HG changeset patch # User Igor Sysoev # Date 1207310833 0 # Node ID 3e9e4581fbba8a97a779b44761e1eafc547b2ea7 # Parent fe30478341f00fcedd01c976bddd0890bce22eb2 fix peer sendfile capability diff --git a/src/http/ngx_http_upstream.c b/src/http/ngx_http_upstream.c --- a/src/http/ngx_http_upstream.c +++ b/src/http/ngx_http_upstream.c @@ -333,7 +333,6 @@ ngx_http_upstream_init(ngx_http_request_ clcf = ngx_http_get_module_loc_conf(r, ngx_http_core_module); - u->output.sendfile = c->sendfile; u->output.pool = r->pool; u->output.bufs.num = 1; u->output.bufs.size = clcf->client_body_buffer_size; @@ -702,6 +701,7 @@ ngx_http_upstream_connect(ngx_http_reque c->read->handler = ngx_http_upstream_process_header; c->sendfile &= r->connection->sendfile; + u->output.sendfile = c->sendfile; c->pool = r->pool; c->read->log = c->write->log = c->log = r->connection->log;