# HG changeset patch # User Igor Sysoev # Date 1189454400 -14400 # Node ID 3f511163d90862acd9a0d46304e910b515d6c52f # Parent 1372b2a4ec2f2c2765b453c827c0de511dda7f3b nginx 0.6.11 *) Bugfix: active connection counter always increased if mail proxy was used. *) Bugfix: if backend returned response header only using non-buffered proxy, then nginx closed backend connection on timeout. *) Bugfix: nginx did not support several "Connection" request header lines. *) Bugfix: if the "max_fails" was set for upstream server, then after first failure server weight was always one; bug appeared in 0.6.6. diff --git a/src/core/nginx.h b/src/core/nginx.h --- a/src/core/nginx.h +++ b/src/core/nginx.h @@ -8,7 +8,7 @@ #define _NGINX_H_INCLUDED_ -#define NGINX_VERSION "0.6.10" +#define NGINX_VERSION "0.6.11" #define NGINX_VER "nginx/" NGINX_VERSION #define NGINX_VAR "NGINX" diff --git a/src/http/modules/perl/nginx.pm b/src/http/modules/perl/nginx.pm --- a/src/http/modules/perl/nginx.pm +++ b/src/http/modules/perl/nginx.pm @@ -47,7 +47,7 @@ our @EXPORT = qw( HTTP_INSUFFICIENT_STORAGE ); -our $VERSION = '0.6.10'; +our $VERSION = '0.6.11'; require XSLoader; XSLoader::load('nginx', $VERSION); diff --git a/src/http/ngx_http_upstream_round_robin.c b/src/http/ngx_http_upstream_round_robin.c --- a/src/http/ngx_http_upstream_round_robin.c +++ b/src/http/ngx_http_upstream_round_robin.c @@ -514,8 +514,8 @@ ngx_http_upstream_get_peer(ngx_http_upst } for (i = 0; i < peers->number; i++) { - if (peer[i].fails == 0) { - peer[i].current_weight = peer[i].weight; + if (peer->max_fails == 0 || peer->fails < peer->max_fails) { + peer[i].current_weight += peer[i].weight; } else { /* 1 allows to go to quick recovery when all peers failed */