diff options
Diffstat (limited to 'src/http/ngx_http_core_module.c')
-rw-r--r-- | src/http/ngx_http_core_module.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/http/ngx_http_core_module.c b/src/http/ngx_http_core_module.c index f2f69f4df..bf455d867 100644 --- a/src/http/ngx_http_core_module.c +++ b/src/http/ngx_http_core_module.c @@ -351,13 +351,10 @@ ngx_module_t ngx_http_core_module = { void ngx_http_handler(ngx_http_request_t *r) { - ngx_http_log_ctx_t *ctx; + r->connection->log->action = NULL; r->connection->unexpected_eof = 0; - ctx = r->connection->log->data; - ctx->action = NULL; - switch (r->headers_in.connection_type) { case 0: if (r->http_version > NGX_HTTP_VERSION_10) { @@ -541,6 +538,10 @@ ngx_int_t ngx_http_find_location_config(ngx_http_request_t *r) r->connection->sendfile = 0; } + if (r->keepalive && clcf->keepalive_timeout == 0) { + r->keepalive = 0; + } + if (!clcf->tcp_nopush) { /* disable TCP_NOPUSH/TCP_CORK use */ r->connection->tcp_nopush = NGX_TCP_NOPUSH_DISABLED; |