summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIgor Sysoev <igor@sysoev.ru>2007-12-12 21:05:17 +0000
committerIgor Sysoev <igor@sysoev.ru>2007-12-12 21:05:17 +0000
commit03bb14b2a39cf36951b59c493df2d12cba354a00 (patch)
treedc7bd33d08fdf664985e91b96f8c545d21dbc80e
parentcb4723a288ecfc5b4acf2385f273b21646062bce (diff)
downloadnginx-03bb14b2a39cf36951b59c493df2d12cba354a00.tar.gz
r1657 merge:
log entire request line instead of URI only
-rw-r--r--src/http/ngx_http_request.c31
1 files changed, 12 insertions, 19 deletions
diff --git a/src/http/ngx_http_request.c b/src/http/ngx_http_request.c
index 0af46337e..e5628f23a 100644
--- a/src/http/ngx_http_request.c
+++ b/src/http/ngx_http_request.c
@@ -2599,28 +2599,21 @@ ngx_http_log_error_handler(ngx_http_request_t *r, ngx_http_request_t *sr,
buf = p;
}
- if (r->unparsed_uri.data) {
- p = ngx_snprintf(buf, len, ", URL: \"%V\"", &r->unparsed_uri);
- len -= p - buf;
- buf = p;
-
- } else {
- if (r->request_line.data == NULL && r->request_start) {
- for (p = r->request_start; p < r->header_in->last; p++) {
- if (*p == CR || *p == LF) {
- break;
- }
+ if (r->request_line.data == NULL && r->request_start) {
+ for (p = r->request_start; p < r->header_in->last; p++) {
+ if (*p == CR || *p == LF) {
+ break;
}
-
- r->request_line.len = p - r->request_start;
- r->request_line.data = r->request_start;
}
- if (r->request_line.len) {
- p = ngx_snprintf(buf, len, ", request: \"%V\"", &r->request_line);
- len -= p - buf;
- buf = p;
- }
+ r->request_line.len = p - r->request_start;
+ r->request_line.data = r->request_start;
+ }
+
+ if (r->request_line.len) {
+ p = ngx_snprintf(buf, len, ", request: \"%V\"", &r->request_line);
+ len -= p - buf;
+ buf = p;
}
if (r != sr) {