Mercurial > hg > nginx-quic
changeset 6459:78fc2dce69e7
Stream: detect port absence in proxy_pass with IP literal.
This is a clone of http commit 26c127bab5ef.
author | Roman Arutyunyan <arut@nginx.com> |
---|---|
date | Wed, 23 Mar 2016 17:45:15 +0300 |
parents | 384154fc634f |
children | 034329824dd3 |
files | src/stream/ngx_stream_upstream.c |
diffstat | 1 files changed, 1 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/src/stream/ngx_stream_upstream.c +++ b/src/stream/ngx_stream_upstream.c @@ -388,7 +388,7 @@ ngx_stream_upstream_add(ngx_conf_t *cf, uscf->port = u->port; uscf->no_port = u->no_port; - if (u->naddrs == 1) { + if (u->naddrs == 1 && (u->port || u->family == AF_UNIX)) { uscf->servers = ngx_array_create(cf->pool, 1, sizeof(ngx_stream_upstream_server_t)); if (uscf->servers == NULL) {