diff options
author | Igor Sysoev <igor@sysoev.ru> | 2011-04-04 12:26:53 +0000 |
---|---|---|
committer | Igor Sysoev <igor@sysoev.ru> | 2011-04-04 12:26:53 +0000 |
commit | 4956ac510858c5bc32945bcb87a460b91440ad3e (patch) | |
tree | c3692ef67e1a4fb4d10a4ab213c13844a34173ed /src/core/ngx_cycle.c | |
parent | fde7d51392598d0fa74dca125883d9663e7eb80a (diff) | |
download | nginx-4956ac510858c5bc32945bcb87a460b91440ad3e.tar.gz nginx-4956ac510858c5bc32945bcb87a460b91440ad3e.zip |
reuse keepalive connections if there are no free worker connections
patch by Maxim Dounin
Diffstat (limited to 'src/core/ngx_cycle.c')
-rw-r--r-- | src/core/ngx_cycle.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/core/ngx_cycle.c b/src/core/ngx_cycle.c index 357c6b284..79867079d 100644 --- a/src/core/ngx_cycle.c +++ b/src/core/ngx_cycle.c @@ -181,6 +181,9 @@ ngx_init_cycle(ngx_cycle_t *old_cycle) cycle->listening.pool = pool; + ngx_queue_init(&cycle->reusable_connections_queue); + + cycle->conf_ctx = ngx_pcalloc(pool, ngx_max_module * sizeof(void *)); if (cycle->conf_ctx == NULL) { ngx_destroy_pool(pool); |