sd-network: actually open the state file in sd_network_get_llmnr()

This commit is contained in:
Lennart Poettering
2014-08-04 23:05:26 +02:00
parent 59b8f6b628
commit 2cd666f8c9
+3
View File
@@ -114,6 +114,9 @@ _public_ int sd_network_get_llmnr(int ifindex, char **llmnr) {
assert_return(ifindex > 0, -EINVAL);
assert_return(llmnr, -EINVAL);
if (asprintf(&p, "/run/systemd/netif/links/%d", ifindex) < 0)
return -ENOMEM;
r = parse_env_file(p, NEWLINE, "LLMNR", &s, NULL);
if (r == -ENOENT)
return -ENODATA;