diff options
author | Roman Arutyunyan <arut@nginx.com> | 2014-05-23 13:47:05 +0400 |
---|---|---|
committer | Roman Arutyunyan <arut@nginx.com> | 2014-05-23 13:47:05 +0400 |
commit | 3e279a8eb492ff903ccc46cf03bbd95a30a7dcf1 (patch) | |
tree | 3cf60c39a1154e00d5c5bd26000cb5d36cd98ca3 | |
parent | 7808ac0d42fd8d05d0f925cd113193f38e3b1313 (diff) | |
download | nginx-3e279a8eb492ff903ccc46cf03bbd95a30a7dcf1.tar.gz nginx-3e279a8eb492ff903ccc46cf03bbd95a30a7dcf1.zip |
Upstream: fix tries check in ip_hash.
Make two checks for maximum number of tries consistent.
The other one checks '>' condition.
-rw-r--r-- | src/http/modules/ngx_http_upstream_ip_hash_module.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/http/modules/ngx_http_upstream_ip_hash_module.c b/src/http/modules/ngx_http_upstream_ip_hash_module.c index 041883fec..148d73a84 100644 --- a/src/http/modules/ngx_http_upstream_ip_hash_module.c +++ b/src/http/modules/ngx_http_upstream_ip_hash_module.c @@ -231,7 +231,7 @@ ngx_http_upstream_get_ip_hash_peer(ngx_peer_connection_t *pc, void *data) next: - if (++iphp->tries >= 20) { + if (++iphp->tries > 20) { return iphp->get_rr_peer(pc, &iphp->rrp); } } |