diff options
Diffstat (limited to 'usr.sbin/nginx/src/http/ngx_http.c')
| -rw-r--r-- | usr.sbin/nginx/src/http/ngx_http.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/usr.sbin/nginx/src/http/ngx_http.c b/usr.sbin/nginx/src/http/ngx_http.c index 3e077fb95ab..f1f8a48e08f 100644 --- a/usr.sbin/nginx/src/http/ngx_http.c +++ b/usr.sbin/nginx/src/http/ngx_http.c @@ -1613,6 +1613,11 @@ ngx_http_cmp_conf_addrs(const void *one, const void *two) return 1; } + if (second->opt.wildcard) { + /* a wildcard address must be the last resort, shift it to the end */ + return -1; + } + if (first->opt.bind && !second->opt.bind) { /* shift explicit bind()ed addresses to the start */ return -1; |
