From: Rafał Miłecki Date: Fri, 10 Feb 2017 22:37:12 +0000 (+0100) Subject: Drop one-liner service_announce function X-Git-Url: http://git.archive.openwrt.org/?a=commitdiff_plain;h=578616a31cd9ba01017f399f5d9a50481019889e;hp=c3c168c1cc39539f5ec452ab2f556e78bfa92917;p=project%2Fmdnsd.git Drop one-liner service_announce function Now we have service_announce simplified so much there is no reason to keep it as a helper. Signed-off-by: Rafał Miłecki Acked-by: John Crispin --- diff --git a/announce.c b/announce.c index 7bbce4a..f04a600 100644 --- a/announce.c +++ b/announce.c @@ -66,7 +66,7 @@ announce_timer(struct uloop_timeout *timeout) case STATE_ANNOUNCE: dns_reply_a(iface, announce_ttl); - service_announce(iface, announce_ttl); + service_announce_services(iface, announce_ttl); uloop_timeout_set(timeout, announce_ttl * 800); break; } diff --git a/interface.c b/interface.c index 463335a..587b188 100644 --- a/interface.c +++ b/interface.c @@ -620,8 +620,8 @@ void interface_shutdown(void) vlist_for_each_element(&interfaces, iface, node) if (iface->fd.fd > 0 && iface->multicast) { - service_announce(iface, 0); dns_reply_a(iface, 0); + service_announce_services(iface, 0); } vlist_for_each_element(&interfaces, iface, node) interface_close(iface); diff --git a/service.c b/service.c index 993e7cf..36d20c7 100644 --- a/service.c +++ b/service.c @@ -169,12 +169,6 @@ service_announce_services(struct interface *iface, int ttl) } } -void -service_announce(struct interface *iface, int ttl) -{ - service_announce_services(iface, ttl); -} - static void service_update(struct vlist_tree *tree, struct vlist_node *node_new, struct vlist_node *node_old) diff --git a/service.h b/service.h index 78ee854..8bc9ba9 100644 --- a/service.h +++ b/service.h @@ -17,7 +17,6 @@ extern char *sdudp; extern void service_init(int announce); extern void service_cleanup(void); -extern void service_announce(struct interface *iface, int ttl); extern void service_reply(struct interface *iface, const char *match, int ttl); extern void service_announce_services(struct interface *iface, int ttl);