mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager
synced 2024-07-21 10:14:41 +00:00
device: skip DNS resolution for tentative IPv6 addresses
A tentative IPv6 address can still fail DAD, so don't use it to resolve the hostname via DNS. Furthermore, tentative addresses can't be used to contact the nameserver and so the resolution will fail if there is no other valid IPv6 address. Wait that the address becomes non-tentative.
This commit is contained in:
parent
ac5325e96b
commit
4138be6a5a
|
@ -17245,6 +17245,9 @@ get_address_for_hostname_dns_lookup(NMDevice *self, int addr_family)
|
|||
return g_inet_address_new_from_bytes(addr->ax.address_ptr, G_SOCKET_FAMILY_IPV4);
|
||||
}
|
||||
|
||||
if (addr->ax.n_ifa_flags & IFA_F_TENTATIVE)
|
||||
continue;
|
||||
|
||||
/* For IPv6 prefer, in order:
|
||||
* - !link-local, !deprecated
|
||||
* - !link-local, deprecated
|
||||
|
|
Loading…
Reference in a new issue