set the error level as default http error_log level

This commit is contained in:
Igor Sysoev 2009-01-16 14:00:05 +00:00
parent 6019a7621b
commit 91cf00da17
2 changed files with 4 additions and 5 deletions

View File

@ -394,10 +394,6 @@ ngx_init_cycle(ngx_cycle_t *old_cycle)
cycle->log = cycle->new_log; cycle->log = cycle->new_log;
pool->log = cycle->new_log; pool->log = cycle->new_log;
if (cycle->log->log_level == 0) {
cycle->log->log_level = NGX_LOG_ERR;
}
/* create shared memory */ /* create shared memory */

View File

@ -302,7 +302,10 @@ ngx_set_error_log_levels(ngx_conf_t *cf, ngx_log_t *log)
} }
} }
if (log->log_level == NGX_LOG_DEBUG) { if (log->log_level == 0) {
log->log_level = NGX_LOG_ERR;
} else if (log->log_level == NGX_LOG_DEBUG) {
log->log_level = NGX_LOG_DEBUG_ALL; log->log_level = NGX_LOG_DEBUG_ALL;
} }