diff src/http/ngx_http_core_module.c @ 643:947c6fd27699 release-0.3.43

nginx-0.3.43-RELEASE import *) Bugfix: in the SSI.
author Igor Sysoev <igor@sysoev.ru>
date Wed, 26 Apr 2006 15:21:08 +0000
parents 5e8fb59c18c1
children 4946078f0a79
line wrap: on
line diff
--- a/src/http/ngx_http_core_module.c
+++ b/src/http/ngx_http_core_module.c
@@ -738,9 +738,11 @@ ngx_http_update_location_config(ngx_http
         clcf = ngx_http_get_module_loc_conf(r, ngx_http_core_module);
     }
 
-    r->connection->log->file = clcf->err_log->file;
-    if (!(r->connection->log->log_level & NGX_LOG_DEBUG_CONNECTION)) {
-        r->connection->log->log_level = clcf->err_log->log_level;
+    if (r == r->main) {
+            r->connection->log->file = clcf->err_log->file;
+        if (!(r->connection->log->log_level & NGX_LOG_DEBUG_CONNECTION)) {
+            r->connection->log->log_level = clcf->err_log->log_level;
+        }
     }
 
     if ((ngx_io.flags & NGX_IO_SENDFILE) && clcf->sendfile) {