mirror of
https://github.com/nginx/nginx.git
synced 2025-06-07 17:52:38 +08:00
Resolver: require name servers.
This commit is contained in:
parent
4542898917
commit
63e8a1d926
@ -275,6 +275,11 @@ ngx_resolver_create(ngx_conf_t *cf, ngx_str_t *names, ngx_uint_t n)
|
||||
}
|
||||
}
|
||||
|
||||
if (n && r->connections.nelts == 0) {
|
||||
ngx_conf_log_error(NGX_LOG_EMERG, cf, 0, "no name servers defined");
|
||||
return NULL;
|
||||
}
|
||||
|
||||
return r;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user