Welcome! Log In Create A New Profile

Advanced

ngx_conf_set_str_array_slot() bug?

August 18, 2014 01:06PM
Hi,
For a module with the following configuration

/**
* do_nothing_tuple "val1" "val2";
*/
static ngx_command_t ngx_http_do_nothing_commands[] = {

{
ngx_string("do_nothing_tuple"),
NGX_HTTP_LOC_CONF | NGX_CONF_TAKE2,
ngx_conf_set_str_array_slot,
NGX_HTTP_LOC_CONF_OFFSET,
offsetof(ngx_http_do_nothing_loc_conf_t, tuple),
NULL
},

ngx_null_command
};

I was expecting that ngx_conf_set_str_array_slot() would create and
initialize an ngx_array_t with two elements (nelts == 2), the given
parameters, but it saves just the first element (see
http://fossies.org/dox/nginx-1.7.4/ngx__conf__file_8c_source.html#l01034).

Is it a bug or ngx_conf_set_str_array_slot() use case is different?

Regards,
Paulo A. Silva
http://tech.pauloasilva.com
http://linkedin.com/in/devpauloasilva/

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

ngx_conf_set_str_array_slot() bug?

PauloASilva 807 August 18, 2014 01:06PM

Re: ngx_conf_set_str_array_slot() bug?

Valentin V. Bartenev 326 August 18, 2014 02:34PM

Re: ngx_conf_set_str_array_slot() bug?

PauloASilva 647 August 18, 2014 07:40PM



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

Online Users

Guests: 80
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