ngx_strlow -- 1




监听连接数组初始化// 监听链接数组初始化 n = old_cycle->listening.nelts ? old_cycle->listening.nelts : 10; cycle->listening.elts = ngx_pcalloc(pool, n * sizeof(ngx_listening_t)); if (cycle->listening.elts == NULL) { ngx_destroy_pool(pool); return NULL; } cycle->listening.nelts = 0; cycle->listening.size = sizeof(ngx_listening_t); cycle->listening.nalloc = n; cycle->listening.pool = pool; 这段代码比较简单,主要是数组的创建和初始化操作复用连接队列初始化// nginx 复用连接队列初始化 ngx_queue_init(&cycle->reusable_connections_queue); 循环双向链表结构 -- ngx_queue_t复用连接队列是一个循环双向链表结构 ngx_queue_ttypedef struc
#技术帖    #龙潭书斋    #nginx    #opensource   



京ICP备15018585号