comparison src/http/ngx_http_upstream.c @ 264:4de4f8bc5d07 NGINX_0_5_2

nginx 0.5.2 *) Bugfix: if the "proxy_pass" directive used the name of the "upstream" block, then nginx tried to resolve the name; bug appeared in 0.5.1.
author Igor Sysoev <http://sysoev.ru>
date Mon, 11 Dec 2006 00:00:00 +0300
parents e0b1d0a6c629
children 251bcd11a5b8
comparison
equal deleted inserted replaced
263:34f7e991e4f7 264:4de4f8bc5d07
2841 umcf = ngx_http_conf_get_module_main_conf(cf, ngx_http_upstream_module); 2841 umcf = ngx_http_conf_get_module_main_conf(cf, ngx_http_upstream_module);
2842 2842
2843 uscfp = umcf->upstreams.elts; 2843 uscfp = umcf->upstreams.elts;
2844 2844
2845 for (i = 0; i < umcf->upstreams.nelts; i++) { 2845 for (i = 0; i < umcf->upstreams.nelts; i++) {
2846 if (uscfp[i]->port != u->portn 2846 if ((uscfp[i]->port && uscfp[i]->port != u->portn)
2847 || uscfp[i]->host.len != u->host.len 2847 || uscfp[i]->host.len != u->host.len
2848 || ngx_strncasecmp(uscfp[i]->host.data, u->host.data, u->host.len) 2848 || ngx_strncasecmp(uscfp[i]->host.data, u->host.data, u->host.len)
2849 != 0) 2849 != 0)
2850 { 2850 {
2851 continue; 2851 continue;