mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-02-05 11:10:31 +01:00
dns: don't add an IP-addresss-like hostname to the search domains
https://bugzilla.gnome.org/show_bug.cgi?id=761302
This commit is contained in:
parent
4441dbf3f3
commit
da4ae74fff
1 changed files with 2 additions and 1 deletions
|
|
@ -874,7 +874,8 @@ update_dns (NMDnsManager *self,
|
|||
if (priv->hostname) {
|
||||
const char *hostdomain = strchr (priv->hostname, '.');
|
||||
|
||||
if (hostdomain) {
|
||||
if ( hostdomain
|
||||
&& !nm_utils_ipaddr_valid (AF_UNSPEC, priv->hostname)) {
|
||||
hostdomain++;
|
||||
if (DOMAIN_IS_VALID (hostdomain))
|
||||
add_string_item (rc.searches, hostdomain);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue