From 1ade96e980d3c0855a04140f4728b3ffd429bbea Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Fri, 18 Dec 2015 14:16:48 +0100 Subject: resolved: don't complain if networkd doesn't know an interface we care about --- src/resolve/resolved-link.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'src/resolve') diff --git a/src/resolve/resolved-link.c b/src/resolve/resolved-link.c index 84100bd988..0fe2bb30bd 100644 --- a/src/resolve/resolved-link.c +++ b/src/resolve/resolved-link.c @@ -183,6 +183,10 @@ static int link_update_dns_servers(Link *l) { assert(l); r = sd_network_link_get_dns(l->ifindex, &nameservers); + if (r == -ENODATA) { + r = 0; + goto clear; + } if (r < 0) goto clear; @@ -222,6 +226,10 @@ static int link_update_llmnr_support(Link *l) { assert(l); r = sd_network_link_get_llmnr(l->ifindex, &b); + if (r == -ENODATA) { + r = 0; + goto clear; + } if (r < 0) goto clear; @@ -252,6 +260,11 @@ static int link_update_search_domains(Link *l) { assert(l); r = sd_network_link_get_domains(l->ifindex, &domains); + if (r == -ENODATA) { + /* networkd knows nothing about this interface, and that's fine. */ + r = 0; + goto clear; + } if (r < 0) goto clear; -- cgit v1.2.3-54-g00ecf