comparison src/http/ngx_http_core_module.c @ 520:d41628eb4d0a NGINX_0_8_12

nginx 0.8.12 *) Feature: the "sendfile" parameter in the "aio" directive on FreeBSD. *) Bugfix: in try_files; the bug had appeared in 0.8.11. *) Bugfix: in memcached; the bug had appeared in 0.8.11.
author Igor Sysoev <http://sysoev.ru>
date Mon, 31 Aug 2009 00:00:00 +0400
parents 86dad910eeb6
children 80f7156c2965
comparison
equal deleted inserted replaced
519:1fd1b769cd78 520:d41628eb4d0a
102 { ngx_string("clean"), NGX_HTTP_REQUEST_BODY_FILE_CLEAN }, 102 { ngx_string("clean"), NGX_HTTP_REQUEST_BODY_FILE_CLEAN },
103 { ngx_null_string, 0 } 103 { ngx_null_string, 0 }
104 }; 104 };
105 105
106 106
107 #if (NGX_HAVE_FILE_AIO)
108
109 static ngx_conf_enum_t ngx_http_core_aio[] = {
110 { ngx_string("off"), NGX_HTTP_AIO_OFF },
111 { ngx_string("on"), NGX_HTTP_AIO_ON },
112 #if (NGX_HAVE_AIO_SENDFILE)
113 { ngx_string("sendfile"), NGX_HTTP_AIO_SENDFILE },
114 #endif
115 { ngx_null_string, 0 }
116 };
117
118 #endif
119
120
107 static ngx_conf_enum_t ngx_http_core_satisfy[] = { 121 static ngx_conf_enum_t ngx_http_core_satisfy[] = {
108 { ngx_string("all"), NGX_HTTP_SATISFY_ALL }, 122 { ngx_string("all"), NGX_HTTP_SATISFY_ALL },
109 { ngx_string("any"), NGX_HTTP_SATISFY_ANY }, 123 { ngx_string("any"), NGX_HTTP_SATISFY_ANY },
110 { ngx_null_string, 0 } 124 { ngx_null_string, 0 }
111 }; 125 };
384 NULL }, 398 NULL },
385 399
386 #if (NGX_HAVE_FILE_AIO) 400 #if (NGX_HAVE_FILE_AIO)
387 401
388 { ngx_string("aio"), 402 { ngx_string("aio"),
389 NGX_HTTP_MAIN_CONF|NGX_HTTP_SRV_CONF|NGX_HTTP_LOC_CONF|NGX_CONF_FLAG, 403 NGX_HTTP_MAIN_CONF|NGX_HTTP_SRV_CONF|NGX_HTTP_LOC_CONF|NGX_CONF_TAKE1,
390 ngx_conf_set_flag_slot, 404 ngx_conf_set_enum_slot,
391 NGX_HTTP_LOC_CONF_OFFSET, 405 NGX_HTTP_LOC_CONF_OFFSET,
392 offsetof(ngx_http_core_loc_conf_t, aio), 406 offsetof(ngx_http_core_loc_conf_t, aio),
393 NULL }, 407 &ngx_http_core_aio },
394 408
395 #endif 409 #endif
396 410
397 { ngx_string("directio"), 411 { ngx_string("directio"),
398 NGX_HTTP_MAIN_CONF|NGX_HTTP_SRV_CONF|NGX_HTTP_LOC_CONF|NGX_CONF_TAKE1, 412 NGX_HTTP_MAIN_CONF|NGX_HTTP_SRV_CONF|NGX_HTTP_LOC_CONF|NGX_CONF_TAKE1,
1199 ngx_http_split_args(r, &path, &args); 1213 ngx_http_split_args(r, &path, &args);
1200 1214
1201 (void) ngx_http_internal_redirect(r, &path, &args); 1215 (void) ngx_http_internal_redirect(r, &path, &args);
1202 } 1216 }
1203 1217
1218 ngx_http_finalize_request(r, NGX_DONE);
1204 return NGX_OK; 1219 return NGX_OK;
1205 } 1220 }
1206 1221
1207 ngx_memzero(&of, sizeof(ngx_open_file_info_t)); 1222 ngx_memzero(&of, sizeof(ngx_open_file_info_t));
1208 1223
2137 r->main->subrequests++; 2152 r->main->subrequests++;
2138 r->main->count++; 2153 r->main->count++;
2139 2154
2140 *psr = sr; 2155 *psr = sr;
2141 2156
2142 return ngx_http_post_request(sr); 2157 return ngx_http_post_request(sr, NULL);
2143 } 2158 }
2144 2159
2145 2160
2146 ngx_int_t 2161 ngx_int_t
2147 ngx_http_internal_redirect(ngx_http_request_t *r, 2162 ngx_http_internal_redirect(ngx_http_request_t *r,