projects
/
project
/
odhcpd.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
config: add option to indicate dns service presence
[project/odhcpd.git]
/
src
/
odhcpd.c
diff --git
a/src/odhcpd.c
b/src/odhcpd.c
index 39e0e5137cf5514555f0ea98420d45bfe284b47d..04a8054264f66eab9ab07ef6709efe22f144d359 100644
(file)
--- a/
src/odhcpd.c
+++ b/
src/odhcpd.c
@@
-253,6
+253,9
@@
int odhcpd_get_interface_dns_addr(const struct interface *iface, struct in6_addr
time_t now = odhcpd_time();
ssize_t m = -1;
+ if (!iface->dns_service)
+ return -1;
+
for (size_t i = 0; i < iface->addr6_len; ++i) {
if (iface->addr6[i].valid <= (uint32_t)now)
continue;