]> git.kaiwu.me - nginx.git/commitdiff
Upstream: fixed logging level of upstream invalid header errors.
authorMaxim Dounin <mdounin@mdounin.ru>
Mon, 18 Oct 2021 13:46:59 +0000 (16:46 +0300)
committerMaxim Dounin <mdounin@mdounin.ru>
Mon, 18 Oct 2021 13:46:59 +0000 (16:46 +0300)
In b87b7092cedb (nginx 1.21.1), logging level of "upstream sent invalid
header" errors was accidentally changed to "info".  This change restores
the "error" level, which is a proper logging level for upstream-side
errors.

src/http/modules/ngx_http_fastcgi_module.c
src/http/modules/ngx_http_proxy_module.c
src/http/modules/ngx_http_scgi_module.c
src/http/modules/ngx_http_uwsgi_module.c

index 69ac0f72c69c215e3bda890b4a5f7901679e8bde..4a8dc338e337201e0ada2f4e44b49d405527db7e 100644 (file)
@@ -2021,7 +2021,7 @@ ngx_http_fastcgi_process_header(ngx_http_request_t *r)
 
             /* rc == NGX_HTTP_PARSE_INVALID_HEADER */
 
-            ngx_log_error(NGX_LOG_INFO, r->connection->log, 0,
+            ngx_log_error(NGX_LOG_ERR, r->connection->log, 0,
                           "upstream sent invalid header: \"%*s\\x%02xd...\"",
                           r->header_end - r->header_name_start,
                           r->header_name_start, *r->header_end);
index a5cc27b1ec35fe082fe2d863eb0a5036775497f9..7c4061c02cf428157d55305e49cf89371cce0261 100644 (file)
@@ -2021,7 +2021,7 @@ ngx_http_proxy_process_header(ngx_http_request_t *r)
 
         /* rc == NGX_HTTP_PARSE_INVALID_HEADER */
 
-        ngx_log_error(NGX_LOG_INFO, r->connection->log, 0,
+        ngx_log_error(NGX_LOG_ERR, r->connection->log, 0,
                       "upstream sent invalid header: \"%*s\\x%02xd...\"",
                       r->header_end - r->header_name_start,
                       r->header_name_start, *r->header_end);
index 570713df98b95659964418d088d1a418c55700e7..e5d31ae91b36c8ff288b146e8d724bc6ad8b8246 100644 (file)
@@ -1142,7 +1142,7 @@ ngx_http_scgi_process_header(ngx_http_request_t *r)
 
         /* rc == NGX_HTTP_PARSE_INVALID_HEADER */
 
-        ngx_log_error(NGX_LOG_INFO, r->connection->log, 0,
+        ngx_log_error(NGX_LOG_ERR, r->connection->log, 0,
                       "upstream sent invalid header: \"%*s\\x%02xd...\"",
                       r->header_end - r->header_name_start,
                       r->header_name_start, *r->header_end);
index 4f9c349c25bed7bb07fb04929876920d25629c92..d46741a00464ceb7c9df198f10c802ebc635a988 100644 (file)
@@ -1363,7 +1363,7 @@ ngx_http_uwsgi_process_header(ngx_http_request_t *r)
 
         /* rc == NGX_HTTP_PARSE_INVALID_HEADER */
 
-        ngx_log_error(NGX_LOG_INFO, r->connection->log, 0,
+        ngx_log_error(NGX_LOG_ERR, r->connection->log, 0,
                       "upstream sent invalid header: \"%*s\\x%02xd...\"",
                       r->header_end - r->header_name_start,
                       r->header_name_start, *r->header_end);