Welcome! Log In Create A New Profile

Advanced

Re: ngx_hash_init

January 19, 2015 09:40AM
thank you very much

2015-01-12 10:19 GMT-05:00 Maxim Dounin <mdounin@mdounin.ru>:

> Hello!
>
> On Thu, Jan 08, 2015 at 12:34:39PM -0500, Ian Labbé wrote:
>
> > Hello,
> >
> > Maybe i am not in the right mailing list, please refer me to the good one
> > if i am at the wrong one.
> >
> > I just want to understand the " for (size = start; size <=
> hinit->max_size;
> > size++) " loop in the ngx_hash_init function.
> > I do not understand what "size", "key" and "test[key]" mean in first
> place.
>
> The ngx_hash_init() functions tries to build a hash by using a
> varying number of buckets. The "size" variable corresponds to the
> number of buckets we test at the current loop iteration. For each
> size we iterate over all hash items to check how buckets will be
> ("key" is a bucket number for a given hash item, "test[key]"
> stores how many bytes will be stored in the bucket).
>
> --
> Maxim Dounin
> http://nginx.org/
>
> _______________________________________________
> nginx-devel mailing list
> nginx-devel@nginx.org
> http://mailman.nginx.org/mailman/listinfo/nginx-devel




--
Ian Labbé
Chemin des Quatre-Bourgeois
418-529-0210
G1W 2L1
_______________________________________________
nginx-devel mailing list
nginx-devel@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx-devel
Subject Author Views Posted

ngx_hash_init

xdiaod 952 January 08, 2015 12:36PM

Re: ngx_hash_init

Maxim Dounin 346 January 12, 2015 10:20AM

Re: ngx_hash_init

xdiaod 388 January 19, 2015 09:40AM



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

Online Users

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