mirror of
https://github.com/pi-hole/dnsmasq.git
synced 2025-12-19 10:18:25 +00:00
Tidy up RA scheduling.
This commit is contained in:
@@ -831,6 +831,11 @@ static void sig_handler(int sig)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void send_alarm(void)
|
||||||
|
{
|
||||||
|
send_event(pipewrite, EVENT_ALARM, 0, NULL);
|
||||||
|
}
|
||||||
|
|
||||||
void send_event(int fd, int event, int data, char *msg)
|
void send_event(int fd, int event, int data, char *msg)
|
||||||
{
|
{
|
||||||
struct event_desc ev;
|
struct event_desc ev;
|
||||||
|
|||||||
@@ -967,6 +967,7 @@ unsigned char *extended_hwaddr(int hwtype, int hwlen, unsigned char *hwaddr,
|
|||||||
int make_icmp_sock(void);
|
int make_icmp_sock(void);
|
||||||
int icmp_ping(struct in_addr addr);
|
int icmp_ping(struct in_addr addr);
|
||||||
#endif
|
#endif
|
||||||
|
void send_alarm(void);
|
||||||
void send_event(int fd, int event, int data, char *msg);
|
void send_event(int fd, int event, int data, char *msg);
|
||||||
void clear_cache_and_reload(time_t now);
|
void clear_cache_and_reload(time_t now);
|
||||||
void poll_resolv(int force, int do_reload, time_t now);
|
void poll_resolv(int force, int do_reload, time_t now);
|
||||||
|
|||||||
@@ -348,7 +348,7 @@ static void nl_routechange(struct nlmsghdr *h)
|
|||||||
ra_start_unsolicted(dnsmasq_time());
|
ra_start_unsolicted(dnsmasq_time());
|
||||||
/* cause lease_update_file to run after we return, in case we were called from
|
/* cause lease_update_file to run after we return, in case we were called from
|
||||||
iface_enumerate and can't re-enter it now */
|
iface_enumerate and can't re-enter it now */
|
||||||
alarm(1);
|
send_alarm();
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|||||||
@@ -399,7 +399,7 @@ static int iface_search(struct in6_addr *local, int prefix,
|
|||||||
int scope, int if_index, int dad, void *vparam)
|
int scope, int if_index, int dad, void *vparam)
|
||||||
{
|
{
|
||||||
struct search_param *param = vparam;
|
struct search_param *param = vparam;
|
||||||
struct dhcp_context *context, *tmp;
|
struct dhcp_context *context;
|
||||||
|
|
||||||
(void)scope;
|
(void)scope;
|
||||||
(void)dad;
|
(void)dad;
|
||||||
|
|||||||
Reference in New Issue
Block a user