Mercurial > hg > nginx
comparison src/http/ngx_http_core_module.c @ 4356:c8695c991cb8 stable-1.0
Merge of r4267, r4301:
Fix of the "keepalive_disable" directive.
author | Maxim Dounin <mdounin@mdounin.ru> |
---|---|
date | Wed, 14 Dec 2011 13:40:25 +0000 |
parents | b79dbadb3d5e |
children | efd515ace6bb |
comparison
equal
deleted
inserted
replaced
4355:d0e52213406f | 4356:c8695c991cb8 |
---|---|
141 { ngx_string("before"), NGX_HTTP_IMS_BEFORE }, | 141 { ngx_string("before"), NGX_HTTP_IMS_BEFORE }, |
142 { ngx_null_string, 0 } | 142 { ngx_null_string, 0 } |
143 }; | 143 }; |
144 | 144 |
145 | 145 |
146 static ngx_conf_enum_t ngx_http_core_keepalive_disable[] = { | 146 static ngx_conf_bitmask_t ngx_http_core_keepalive_disable[] = { |
147 { ngx_string("none"), NGX_HTTP_KEEPALIVE_DISABLE_NONE }, | 147 { ngx_string("none"), NGX_HTTP_KEEPALIVE_DISABLE_NONE }, |
148 { ngx_string("msie6"), NGX_HTTP_KEEPALIVE_DISABLE_MSIE6 }, | 148 { ngx_string("msie6"), NGX_HTTP_KEEPALIVE_DISABLE_MSIE6 }, |
149 { ngx_string("safari"), NGX_HTTP_KEEPALIVE_DISABLE_SAFARI }, | 149 { ngx_string("safari"), NGX_HTTP_KEEPALIVE_DISABLE_SAFARI }, |
150 { ngx_null_string, 0 } | 150 { ngx_null_string, 0 } |
151 }; | 151 }; |
511 NGX_HTTP_LOC_CONF_OFFSET, | 511 NGX_HTTP_LOC_CONF_OFFSET, |
512 offsetof(ngx_http_core_loc_conf_t, keepalive_requests), | 512 offsetof(ngx_http_core_loc_conf_t, keepalive_requests), |
513 NULL }, | 513 NULL }, |
514 | 514 |
515 { ngx_string("keepalive_disable"), | 515 { ngx_string("keepalive_disable"), |
516 NGX_HTTP_MAIN_CONF|NGX_HTTP_SRV_CONF|NGX_HTTP_LOC_CONF|NGX_CONF_TAKE1, | 516 NGX_HTTP_MAIN_CONF|NGX_HTTP_SRV_CONF|NGX_HTTP_LOC_CONF|NGX_CONF_TAKE12, |
517 ngx_conf_set_enum_slot, | 517 ngx_conf_set_bitmask_slot, |
518 NGX_HTTP_LOC_CONF_OFFSET, | 518 NGX_HTTP_LOC_CONF_OFFSET, |
519 offsetof(ngx_http_core_loc_conf_t, keepalive_disable), | 519 offsetof(ngx_http_core_loc_conf_t, keepalive_disable), |
520 &ngx_http_core_keepalive_disable }, | 520 &ngx_http_core_keepalive_disable }, |
521 | 521 |
522 { ngx_string("satisfy"), | 522 { ngx_string("satisfy"), |
3262 * clcf->regex = NULL; | 3262 * clcf->regex = NULL; |
3263 * clcf->exact_match = 0; | 3263 * clcf->exact_match = 0; |
3264 * clcf->auto_redirect = 0; | 3264 * clcf->auto_redirect = 0; |
3265 * clcf->alias = 0; | 3265 * clcf->alias = 0; |
3266 * clcf->gzip_proxied = 0; | 3266 * clcf->gzip_proxied = 0; |
3267 * clcf->keepalive_disable = 0; | |
3267 */ | 3268 */ |
3268 | 3269 |
3269 clcf->client_max_body_size = NGX_CONF_UNSET; | 3270 clcf->client_max_body_size = NGX_CONF_UNSET; |
3270 clcf->client_body_buffer_size = NGX_CONF_UNSET_SIZE; | 3271 clcf->client_body_buffer_size = NGX_CONF_UNSET_SIZE; |
3271 clcf->client_body_timeout = NGX_CONF_UNSET_MSEC; | 3272 clcf->client_body_timeout = NGX_CONF_UNSET_MSEC; |
3272 clcf->keepalive_disable = NGX_CONF_UNSET_UINT; | |
3273 clcf->satisfy = NGX_CONF_UNSET_UINT; | 3273 clcf->satisfy = NGX_CONF_UNSET_UINT; |
3274 clcf->if_modified_since = NGX_CONF_UNSET_UINT; | 3274 clcf->if_modified_since = NGX_CONF_UNSET_UINT; |
3275 clcf->max_ranges = NGX_CONF_UNSET_UINT; | 3275 clcf->max_ranges = NGX_CONF_UNSET_UINT; |
3276 clcf->client_body_in_file_only = NGX_CONF_UNSET_UINT; | 3276 clcf->client_body_in_file_only = NGX_CONF_UNSET_UINT; |
3277 clcf->client_body_in_single_buffer = NGX_CONF_UNSET; | 3277 clcf->client_body_in_single_buffer = NGX_CONF_UNSET; |
3470 prev->client_body_buffer_size, | 3470 prev->client_body_buffer_size, |
3471 (size_t) 2 * ngx_pagesize); | 3471 (size_t) 2 * ngx_pagesize); |
3472 ngx_conf_merge_msec_value(conf->client_body_timeout, | 3472 ngx_conf_merge_msec_value(conf->client_body_timeout, |
3473 prev->client_body_timeout, 60000); | 3473 prev->client_body_timeout, 60000); |
3474 | 3474 |
3475 ngx_conf_merge_uint_value(conf->keepalive_disable, prev->keepalive_disable, | 3475 ngx_conf_merge_bitmask_value(conf->keepalive_disable, |
3476 NGX_HTTP_KEEPALIVE_DISABLE_MSIE6 | 3476 prev->keepalive_disable, |
3477 |NGX_HTTP_KEEPALIVE_DISABLE_SAFARI); | 3477 (NGX_CONF_BITMASK_SET |
3478 |NGX_HTTP_KEEPALIVE_DISABLE_MSIE6 | |
3479 |NGX_HTTP_KEEPALIVE_DISABLE_SAFARI)); | |
3478 ngx_conf_merge_uint_value(conf->satisfy, prev->satisfy, | 3480 ngx_conf_merge_uint_value(conf->satisfy, prev->satisfy, |
3479 NGX_HTTP_SATISFY_ALL); | 3481 NGX_HTTP_SATISFY_ALL); |
3480 ngx_conf_merge_uint_value(conf->if_modified_since, prev->if_modified_since, | 3482 ngx_conf_merge_uint_value(conf->if_modified_since, prev->if_modified_since, |
3481 NGX_HTTP_IMS_EXACT); | 3483 NGX_HTTP_IMS_EXACT); |
3482 ngx_conf_merge_uint_value(conf->max_ranges, prev->max_ranges, | 3484 ngx_conf_merge_uint_value(conf->max_ranges, prev->max_ranges, |