allow to "set" $http_, $sent_http_, and $upstream_http_ variables

This commit is contained in:
Igor Sysoev 2007-05-01 19:58:45 +00:00
parent 60e8440bf7
commit 9c710c0569

View File

@ -935,7 +935,11 @@ ngx_http_rewrite_set(ngx_conf_t *cf, ngx_command_t *cmd, void *conf)
return NGX_CONF_ERROR;
}
if (v->get_handler == NULL) {
if (v->get_handler == NULL
&& ngx_strncasecmp(value[1].data, "http_", 5) != 0
&& ngx_strncasecmp(value[1].data, "sent_http_", 10) != 0
&& ngx_strncasecmp(value[1].data, "upstream_http_", 14) != 0)
{
v->get_handler = ngx_http_rewrite_var;
v->data = index;
}