mirror of
https://github.com/nginx/nginx.git
synced 2024-12-20 14:13:33 -06:00
Events: simplified cycle in ngx_event_expire_timers().
This commit is contained in:
parent
246152c864
commit
16403bc7b1
@ -67,9 +67,12 @@ ngx_event_expire_timers(void)
|
||||
|
||||
node = ngx_rbtree_min(root, sentinel);
|
||||
|
||||
/* node->key <= ngx_current_time */
|
||||
/* node->key > ngx_current_time */
|
||||
|
||||
if ((ngx_msec_int_t) (node->key - ngx_current_msec) > 0) {
|
||||
return;
|
||||
}
|
||||
|
||||
if ((ngx_msec_int_t) (node->key - ngx_current_msec) <= 0) {
|
||||
ev = (ngx_event_t *) ((char *) node - offsetof(ngx_event_t, timer));
|
||||
|
||||
ngx_log_debug2(NGX_LOG_DEBUG_EVENT, ev->log, 0,
|
||||
@ -89,10 +92,5 @@ ngx_event_expire_timers(void)
|
||||
ev->timedout = 1;
|
||||
|
||||
ev->handler(ev);
|
||||
|
||||
continue;
|
||||
}
|
||||
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user