]> git.kaiwu.me - nginx.git/commitdiff
nginx-0.0.3-2004-04-29-20:34:26 import
authorIgor Sysoev <igor@sysoev.ru>
Thu, 29 Apr 2004 16:34:26 +0000 (16:34 +0000)
committerIgor Sysoev <igor@sysoev.ru>
Thu, 29 Apr 2004 16:34:26 +0000 (16:34 +0000)
src/event/ngx_event.c

index b3f6a5620a41fb573526a072e602e2f150f77877..18fa6b6ef63d76bfdbb7d84b2eeddab5d4236a73 100644 (file)
@@ -190,10 +190,7 @@ static ngx_int_t ngx_event_module_init(ngx_cycle_t *cycle)
         return NGX_ERROR;
     }
 
-    if (ecf->accept_mutex) {
-        ngx_accept_mutex_ptr = (ngx_atomic_t *) shared;
-    }
-
+    ngx_accept_mutex_ptr = (ngx_atomic_t *) shared;
     ngx_connection_counter = (ngx_atomic_t *) (shared + 128);
 
     ngx_log_debug2(NGX_LOG_DEBUG_EVENT, cycle->log, 0,
@@ -220,11 +217,10 @@ static ngx_int_t ngx_event_process_init(ngx_cycle_t *cycle)
     ngx_iocp_conf_t     *iocpcf;
 #endif
 
-
     ccf = (ngx_core_conf_t *) ngx_get_conf(cycle->conf_ctx, ngx_core_module);
     ecf = ngx_event_get_conf(cycle->conf_ctx, ngx_event_core_module);
 
-    if (ccf->worker_processes > 1 && ngx_accept_mutex_ptr) {
+    if (ccf->worker_processes > 1 && ecf->accept_mutex) {
         ngx_accept_mutex = ngx_accept_mutex_ptr;
         ngx_accept_mutex_held = 1;
         ngx_accept_mutex_delay = ecf->accept_mutex_delay;