Pass PCRE_CASELESS to pcre_compile() for caseless matching.

Previously, we sometimes passed constant value 1 that happens to
match PCRE_CASELESS and thus was harmless.
This commit is contained in:
Ruslan Ermilov 2013-03-29 08:47:37 +00:00
parent f24f5f116f
commit 600f9d3ea8

View File

@ -3256,7 +3256,7 @@ ngx_http_core_regex_location(ngx_conf_t *cf, ngx_http_core_loc_conf_t *clcf,
#if (NGX_HAVE_CASELESS_FILESYSTEM)
rc.options = NGX_REGEX_CASELESS;
#else
rc.options = caseless;
rc.options = caseless ? NGX_REGEX_CASELESS : 0;
#endif
clcf->regex = ngx_http_regex_compile(cf, &rc);