From c5371672852b64e7337f08d78ff4c1b3c0b6d159 Mon Sep 17 00:00:00 2001 From: Igor Sysoev Date: Wed, 4 Feb 2004 20:30:08 +0000 Subject: nginx-0.0.2-2004-02-04-23:30:08 import --- src/core/nginx.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'src/core/nginx.c') diff --git a/src/core/nginx.c b/src/core/nginx.c index 21a22d0ba..43f40c58d 100644 --- a/src/core/nginx.c +++ b/src/core/nginx.c @@ -221,7 +221,7 @@ int main(int argc, char *const *argv, char **envp) } -/* TODO: broken single process */ +/* TODO: broken NGX_PROCESS_SINGLE */ static void ngx_master_process_cycle(ngx_cycle_t *cycle, ngx_master_ctx_t *ctx) { @@ -634,6 +634,12 @@ static void ngx_worker_process_cycle(ngx_cycle_t *cycle, void *data) ngx_log_debug0(NGX_LOG_DEBUG_EVENT, cycle->log, 0, "worker cycle"); ngx_process_events(cycle->log); + + if (ngx_reopen) { + ngx_log_error(NGX_LOG_INFO, cycle->log, 0, "reopen logs"); + ngx_reopen_files(cycle, -1); + ngx_reopen = 0; + } } } -- cgit