summaryrefslogtreecommitdiffhomepage
path: root/src/http
diff options
context:
space:
mode:
authorVladimir Homutov <vl@nginx.com>2015-04-25 22:44:02 +0300
committerVladimir Homutov <vl@nginx.com>2015-04-25 22:44:02 +0300
commitdf555ffce6fe6416cc874dcd69a64584c6c7f5e8 (patch)
tree197ff71ba0b0d9dfa4da7f70e6c5bb1d18ff3c1c /src/http
parentd61f21c5e8735da57fb1e1c1a91103e71f5c6207 (diff)
downloadnginx-df555ffce6fe6416cc874dcd69a64584c6c7f5e8.tar.gz
nginx-df555ffce6fe6416cc874dcd69a64584c6c7f5e8.tar.bz2
Core: the ngx_set_connection_log() macro.
The http and stream versions of this macro were identical.
Diffstat (limited to 'src/http')
-rw-r--r--src/http/ngx_http_core_module.c2
-rw-r--r--src/http/ngx_http_request.c6
-rw-r--r--src/http/ngx_http_request.h11
3 files changed, 4 insertions, 15 deletions
diff --git a/src/http/ngx_http_core_module.c b/src/http/ngx_http_core_module.c
index 096a561c4..81960414f 100644
--- a/src/http/ngx_http_core_module.c
+++ b/src/http/ngx_http_core_module.c
@@ -1445,7 +1445,7 @@ ngx_http_update_location_config(ngx_http_request_t *r)
}
if (r == r->main) {
- ngx_http_set_connection_log(r->connection, clcf->error_log);
+ ngx_set_connection_log(r->connection, clcf->error_log);
}
if ((ngx_io.flags & NGX_IO_SENDFILE) && clcf->sendfile) {
diff --git a/src/http/ngx_http_request.c b/src/http/ngx_http_request.c
index a0d75ff87..2669b522c 100644
--- a/src/http/ngx_http_request.c
+++ b/src/http/ngx_http_request.c
@@ -543,7 +543,7 @@ ngx_http_create_request(ngx_connection_t *c)
clcf = ngx_http_get_module_loc_conf(r, ngx_http_core_module);
- ngx_http_set_connection_log(r->connection, clcf->error_log);
+ ngx_set_connection_log(r->connection, clcf->error_log);
r->header_in = hc->nbusy ? hc->busy[0] : c->buffer;
@@ -867,7 +867,7 @@ ngx_http_ssl_servername(ngx_ssl_conn_t *ssl_conn, int *ad, void *arg)
clcf = ngx_http_get_module_loc_conf(hc->conf_ctx, ngx_http_core_module);
- ngx_http_set_connection_log(c, clcf->error_log);
+ ngx_set_connection_log(c, clcf->error_log);
sscf = ngx_http_get_module_srv_conf(hc->conf_ctx, ngx_http_ssl_module);
@@ -2073,7 +2073,7 @@ ngx_http_set_virtual_server(ngx_http_request_t *r, ngx_str_t *host)
clcf = ngx_http_get_module_loc_conf(r, ngx_http_core_module);
- ngx_http_set_connection_log(r->connection, clcf->error_log);
+ ngx_set_connection_log(r->connection, clcf->error_log);
return NGX_OK;
}
diff --git a/src/http/ngx_http_request.h b/src/http/ngx_http_request.h
index ead4d236f..3954de3f1 100644
--- a/src/http/ngx_http_request.h
+++ b/src/http/ngx_http_request.h
@@ -586,17 +586,6 @@ extern ngx_http_header_t ngx_http_headers_in[];
extern ngx_http_header_out_t ngx_http_headers_out[];
-#define ngx_http_set_connection_log(c, l) \
- \
- c->log->file = l->file; \
- c->log->next = l->next; \
- c->log->writer = l->writer; \
- c->log->wdata = l->wdata; \
- if (!(c->log->log_level & NGX_LOG_DEBUG_CONNECTION)) { \
- c->log->log_level = l->log_level; \
- }
-
-
#define ngx_http_set_log_request(log, r) \
((ngx_http_log_ctx_t *) log->data)->current_request = r