Welcome! Log In Create A New Profile

Advanced

Re: Lua Variable access bug?

agentzh
May 17, 2012 07:44AM
On Thu, May 17, 2012 at 5:02 PM, Maxim Dounin <mdounin@mdounin.ru> wrote:
> Shouldn't it be
>
> --- a/src/http/ngx_http_variables.c
> +++ b/src/http/ngx_http_variables.c
> @@ -2072,6 +2072,11 @@ ngx_http_variables_init_vars(ngx_conf_t
>     v = cmcf->variables.elts;
>     key = cmcf->variables_keys->keys.elts;
>
> +    for (n = 0; n < cmcf->variables_keys->keys.nelts; n++) {
> +        av = key[n].value;
> +        av->flags &= ~NGX_HTTP_VAR_INDEXED;
> +    }
> +
>     for (i = 0; i < cmcf->variables.nelts; i++) {
>
>         for (n = 0; n < cmcf->variables_keys->keys.nelts; n++) {
>
>
> instead?
>

Yes, this patch is better and is more efficient :)

> (completely untested)
>

I've tested it on my side and it indeed solves this problem.

Thanks!
-agentzh

_______________________________________________
nginx-devel mailing list
nginx-devel@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx-devel
Subject Author Views Posted

Lua Variable access bug?

Sirsiwal, Umesh 1683 May 15, 2012 10:18PM

Re: Lua Variable access bug? Attachments

agentzh 509 May 17, 2012 04:36AM

Re: Lua Variable access bug?

Maxim Dounin 497 May 17, 2012 05:04AM

Re: Lua Variable access bug?

agentzh 477 May 17, 2012 07:44AM

Re: Lua Variable access bug?

Maxim Dounin 466 May 17, 2012 09:08AM

Re: Lua Variable access bug?

agentzh 530 May 17, 2012 09:16AM

Re: Lua Variable access bug?

Sirsiwal, Umesh 488 May 17, 2012 09:38AM

Re: Lua Variable access bug?

Maxim Dounin 526 May 17, 2012 02:12PM

Re: Lua Variable access bug?

lanshun zhou 482 May 17, 2012 11:00PM

Re: Lua Variable access bug?

Maxim Dounin 593 May 18, 2012 07:10AM

Re: Lua Variable access bug? Attachments

lanshun zhou 604 May 22, 2012 06:34AM



Sorry, you do not have permission to post/reply in this forum.

Online Users

Guests: 223
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready