projects
/
project
/
mdnsd.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
interface: use a global socket instead of per-interface ones
[project/mdnsd.git]
/
dns.c
diff --git
a/dns.c
b/dns.c
index 3e902d019df417fd5443d436c956992cf99fdc5a..2ebb6241deef9d5ca135efd7705a952ea6688959 100644
(file)
--- a/
dns.c
+++ b/
dns.c
@@
-354,8
+354,8
@@
parse_question(struct interface *iface, struct sockaddr *from, char *name, struc
/* TODO: Multicast if more than one quarter of TTL has passed */
if (q->class & CLASS_UNICAST) {
to = from;
/* TODO: Multicast if more than one quarter of TTL has passed */
if (q->class & CLASS_UNICAST) {
to = from;
- if (i
face->multicast
)
- iface = i
face->peer
;
+ if (i
nterface_multicast(iface)
)
+ iface = i
nterface_get(iface->name, iface->type | SOCKTYPE_BIT_UNICAST)
;
}
DBG(1, "Q -> %s %s\n", dns_type_string(q->type), name);
}
DBG(1, "Q -> %s %s\n", dns_type_string(q->type), name);
@@
-412,7
+412,7
@@
dns_handle_packet(struct interface *iface, struct sockaddr *from, uint16_t port,
return;
}
return;
}
- if (h->questions && !i
face->multicast
&& port != MCAST_PORT)
+ if (h->questions && !i
nterface_multicast(iface)
&& port != MCAST_PORT)
/* silently drop unicast questions that dont originate from port 5353 */
return;
/* silently drop unicast questions that dont originate from port 5353 */
return;