From b3df0b34c14ffdaf8f2d72c08ff59da14cd6f7d7 Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Mon, 4 Aug 2014 23:06:05 +0200 Subject: [PATCH] sd-network: when the LLMNR setting is not known for an interface consider that as ENODATA ENODATA should be returned whenever we have no idea about something. A missing LLMNR setting can only really happen during upgrades, in whichc ase we really have no idea, so let's turn this into another ENODATA case. --- src/network/sd-network.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/network/sd-network.c b/src/network/sd-network.c index 260ca470d..ed02eccaf 100644 --- a/src/network/sd-network.c +++ b/src/network/sd-network.c @@ -122,6 +122,8 @@ _public_ int sd_network_get_llmnr(int ifindex, char **llmnr) { return -ENODATA; else if (r < 0) return r; + else if (!s) + return -ENODATA; *llmnr = s; s = NULL; -- 2.30.2