Mercurial > hg > nginx-vendor-0-5
comparison src/imap/ngx_imap_core_module.c @ 136:3656228c0b56 NGINX_0_3_15
nginx 0.3.15
*) Feature: the new 444 code of the "return" directive to close
connection.
*) Feature: the "so_keepalive" directive in IMAP/POP3 proxy.
*) Bugfix: if there are unclosed connection nginx now calls abort()
only on gracefull quit and active "debug_points" directive.
author | Igor Sysoev <http://sysoev.ru> |
---|---|
date | Wed, 07 Dec 2005 00:00:00 +0300 |
parents | 91372f004adf |
children | 3314be145cb9 |
comparison
equal
deleted
inserted
replaced
135:c1ac76c0e9df | 136:3656228c0b56 |
---|---|
71 { ngx_string("imap_client_buffer"), | 71 { ngx_string("imap_client_buffer"), |
72 NGX_IMAP_MAIN_CONF|NGX_IMAP_SRV_CONF|NGX_CONF_TAKE1, | 72 NGX_IMAP_MAIN_CONF|NGX_IMAP_SRV_CONF|NGX_CONF_TAKE1, |
73 ngx_conf_set_size_slot, | 73 ngx_conf_set_size_slot, |
74 NGX_IMAP_SRV_CONF_OFFSET, | 74 NGX_IMAP_SRV_CONF_OFFSET, |
75 offsetof(ngx_imap_core_srv_conf_t, imap_client_buffer_size), | 75 offsetof(ngx_imap_core_srv_conf_t, imap_client_buffer_size), |
76 NULL }, | |
77 | |
78 { ngx_string("so_keepalive"), | |
79 NGX_IMAP_MAIN_CONF|NGX_IMAP_SRV_CONF|NGX_CONF_FLAG, | |
80 ngx_conf_set_flag_slot, | |
81 NGX_IMAP_SRV_CONF_OFFSET, | |
82 offsetof(ngx_imap_core_srv_conf_t, so_keepalive), | |
76 NULL }, | 83 NULL }, |
77 | 84 |
78 { ngx_string("timeout"), | 85 { ngx_string("timeout"), |
79 NGX_IMAP_MAIN_CONF|NGX_IMAP_SRV_CONF|NGX_CONF_TAKE1, | 86 NGX_IMAP_MAIN_CONF|NGX_IMAP_SRV_CONF|NGX_CONF_TAKE1, |
80 ngx_conf_set_msec_slot, | 87 ngx_conf_set_msec_slot, |
154 if (cscf == NULL) { | 161 if (cscf == NULL) { |
155 return NULL; | 162 return NULL; |
156 } | 163 } |
157 | 164 |
158 cscf->imap_client_buffer_size = NGX_CONF_UNSET_SIZE; | 165 cscf->imap_client_buffer_size = NGX_CONF_UNSET_SIZE; |
166 cscf->protocol = NGX_CONF_UNSET_UINT; | |
159 cscf->timeout = NGX_CONF_UNSET_MSEC; | 167 cscf->timeout = NGX_CONF_UNSET_MSEC; |
160 cscf->protocol = NGX_CONF_UNSET_UINT; | 168 cscf->so_keepalive = NGX_CONF_UNSET; |
161 | 169 |
162 if (ngx_array_init(&cscf->pop3_capabilities, cf->pool, 4, sizeof(ngx_str_t)) | 170 if (ngx_array_init(&cscf->pop3_capabilities, cf->pool, 4, sizeof(ngx_str_t)) |
163 != NGX_OK) | 171 != NGX_OK) |
164 { | 172 { |
165 return NULL; | 173 return NULL; |
190 prev->imap_client_buffer_size, | 198 prev->imap_client_buffer_size, |
191 (size_t) ngx_pagesize); | 199 (size_t) ngx_pagesize); |
192 ngx_conf_merge_msec_value(conf->timeout, prev->timeout, 60000); | 200 ngx_conf_merge_msec_value(conf->timeout, prev->timeout, 60000); |
193 ngx_conf_merge_unsigned_value(conf->protocol, prev->protocol, | 201 ngx_conf_merge_unsigned_value(conf->protocol, prev->protocol, |
194 NGX_IMAP_IMAP_PROTOCOL); | 202 NGX_IMAP_IMAP_PROTOCOL); |
203 ngx_conf_merge_value(conf->so_keepalive, prev->so_keepalive, 0); | |
195 | 204 |
196 | 205 |
197 if (conf->pop3_capabilities.nelts == 0) { | 206 if (conf->pop3_capabilities.nelts == 0) { |
198 conf->pop3_capabilities = prev->pop3_capabilities; | 207 conf->pop3_capabilities = prev->pop3_capabilities; |
199 } | 208 } |