chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
59b8f6b
)
sd-network: actually open the state file in sd_network_get_llmnr()
author
Lennart Poettering
<lennart@poettering.net>
Mon, 4 Aug 2014 21:05:26 +0000
(23:05 +0200)
committer
Lennart Poettering
<lennart@poettering.net>
Mon, 4 Aug 2014 21:05:26 +0000
(23:05 +0200)
src/network/sd-network.c
patch
|
blob
|
history
diff --git
a/src/network/sd-network.c
b/src/network/sd-network.c
index a0f147e02316b9720ed33f21ec18f90bd9c9fa97..260ca470d1142cf08df5e73da069910bbcc6ed02 100644
(file)
--- a/
src/network/sd-network.c
+++ b/
src/network/sd-network.c
@@
-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;