Mercurial > hg > nginx
changeset 5410:16b68c724438
Upstream: fixed "down" and "backup" parsing.
Previously arguments starting with "down" or "backup" were considered
valid, e.g. "server ... downFOO;".
author | Maxim Dounin <mdounin@mdounin.ru> |
---|---|
date | Wed, 02 Oct 2013 15:07:15 +0400 |
parents | 11599a3d0c7c |
children | 5483d9e77b32 |
files | src/http/ngx_http_upstream.c |
diffstat | 1 files changed, 2 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/src/http/ngx_http_upstream.c Wed Oct 02 11:51:04 2013 +0400 +++ b/src/http/ngx_http_upstream.c Wed Oct 02 15:07:15 2013 +0400 @@ -4701,7 +4701,7 @@ continue; } - if (ngx_strncmp(value[i].data, "backup", 6) == 0) { + if (ngx_strcmp(value[i].data, "backup") == 0) { if (!(uscf->flags & NGX_HTTP_UPSTREAM_BACKUP)) { goto invalid; @@ -4712,7 +4712,7 @@ continue; } - if (ngx_strncmp(value[i].data, "down", 4) == 0) { + if (ngx_strcmp(value[i].data, "down") == 0) { if (!(uscf->flags & NGX_HTTP_UPSTREAM_DOWN)) { goto invalid;