diff options
author | Igor Sysoev <igor@sysoev.ru> | 2006-04-07 14:08:04 +0000 |
---|---|---|
committer | Igor Sysoev <igor@sysoev.ru> | 2006-04-07 14:08:04 +0000 |
commit | 94e32ce7f885ecc648ae6377276f8813fc1c9347 (patch) | |
tree | 88da0722e206c60326b466b85ab118c00be13f55 /src/core | |
parent | 7469680c6c32901e7b6082a0e564430b587bbcfa (diff) | |
download | nginx-release-0.3.37.tar.gz nginx-release-0.3.37.zip |
nginx-0.3.37-RELEASE importrelease-0.3.37
*) Feature: the "limit_except" directive.
*) Feature: the "if" directive supports the "!~", "!~*", "-f", and
"!-f" operators.
*) Feature: the ngx_http_perl_module supports the $r->request_body
method.
*) Bugfix: in the ngx_http_addition_filter_module.
Diffstat (limited to 'src/core')
-rw-r--r-- | src/core/nginx.h | 2 | ||||
-rw-r--r-- | src/core/ngx_hash.c | 8 | ||||
-rw-r--r-- | src/core/ngx_inet.c | 4 |
3 files changed, 9 insertions, 5 deletions
diff --git a/src/core/nginx.h b/src/core/nginx.h index 3f910cb26..06e46c0c6 100644 --- a/src/core/nginx.h +++ b/src/core/nginx.h @@ -8,7 +8,7 @@ #define _NGINX_H_INCLUDED_ -#define NGINX_VER "nginx/0.3.36" +#define NGINX_VER "nginx/0.3.37" #define NGINX_VAR "NGINX" #define NGX_OLDPID_EXT ".oldbin" diff --git a/src/core/ngx_hash.c b/src/core/ngx_hash.c index 2876318a3..0ee5e77ca 100644 --- a/src/core/ngx_hash.c +++ b/src/core/ngx_hash.c @@ -164,10 +164,14 @@ ngx_hash_init(ngx_hash_init_t *hinit, ngx_hash_key_t *names, ngx_uint_t nelts) return NGX_ERROR; } - start = nelts / (ngx_cacheline_size / (2 * sizeof(void *)) - 1); + bucket_size = hinit->bucket_size - sizeof(void *); + + start = nelts / (bucket_size / (2 * sizeof(void *)) - 1); start = start ? start : 1; - bucket_size = hinit->bucket_size - sizeof(void *); + if (hinit->max_size > 10000 && hinit->max_size / nelts < 100) { + start = hinit->max_size - 1000; + } for (size = start; size < hinit->max_size; size++) { diff --git a/src/core/ngx_inet.c b/src/core/ngx_inet.c index ee68fc1c2..a42df699b 100644 --- a/src/core/ngx_inet.c +++ b/src/core/ngx_inet.c @@ -21,8 +21,8 @@ */ -static -ngx_inline size_t ngx_sprint_uchar(u_char *text, u_char c, size_t len) +static ngx_inline size_t +ngx_sprint_uchar(u_char *text, u_char c, size_t len) { size_t n; ngx_uint_t c1, c2; |