Commit ac5350fe authored by Thomas Haller's avatar Thomas Haller
Browse files

dns: use 127.0.0.53 address in /etc/resolv.conf with systemd-resolved

https://bugzilla.gnome.org/show_bug.cgi?id=787378
parent 2f3e978f
......@@ -1167,9 +1167,16 @@ update_dns (NMDnsManager *self,
* but only uses the local caching nameserver.
*/
if (caching) {
const char *lladdr = "127.0.0.1";
if (NM_IS_DNS_SYSTEMD_RESOLVED (priv->plugin)) {
/* systemd-resolved uses a different link-local address */
lladdr = "127.0.0.53";
}
g_strfreev (nameservers);
nameservers = g_new0 (char*, 2);
nameservers[0] = g_strdup ("127.0.0.1");
nameservers = g_new0 (char *, 2);
nameservers[0] = g_strdup (lladdr);
}
if (update) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment