diff options
Diffstat (limited to 'src/core/ngx_log.c')
-rw-r--r-- | src/core/ngx_log.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/core/ngx_log.c b/src/core/ngx_log.c index 3da25f0a5..5acbaba73 100644 --- a/src/core/ngx_log.c +++ b/src/core/ngx_log.c @@ -219,6 +219,7 @@ static char *ngx_set_error_log(ngx_conf_t *cf, ngx_command_t *cmd, void *conf) ngx_log_t *ngx_log_init_errlog() { #if (WIN32) + ngx_log.fd = GetStdHandle(STD_ERROR_HANDLE); if (ngx_log.fd == NGX_INVALID_FILE) { @@ -231,7 +232,9 @@ ngx_log_t *ngx_log_init_errlog() } #else + ngx_log.fd = STDERR_FILENO; + #endif ngx_log.log_level = NGX_LOG_INFO; |