mirror of
https://github.com/pi-hole/dnsmasq.git
synced 2025-12-19 18:28:25 +00:00
Send correct O and M bits when advertising only deprecated prefixes.
This commit is contained in:
20
src/radv.c
20
src/radv.c
@@ -272,9 +272,27 @@ static void send_ra(time_t now, int iface, char *iface_name, struct in6_addr *de
|
||||
/* zero net part of address */
|
||||
setaddr6part(&local, addr6part(&local) & ~((context->prefix == 64) ? (u64)-1LL : (1LLU << (128 - context->prefix)) - 1LLU));
|
||||
|
||||
|
||||
if ((context->flags &
|
||||
(CONTEXT_RA_ONLY | CONTEXT_RA_NAME | CONTEXT_RA_STATELESS)))
|
||||
do_slaac = 1;
|
||||
{
|
||||
do_slaac = 1;
|
||||
if (context->flags & CONTEXT_DHCP)
|
||||
{
|
||||
parm.other = 1;
|
||||
if (!(context->flags & CONTEXT_RA_STATELESS))
|
||||
parm.managed = 1;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
/* don't do RA for non-ra-only unless --enable-ra is set */
|
||||
if (option_bool(OPT_RA))
|
||||
{
|
||||
parm.managed = 1;
|
||||
parm.other = 1;
|
||||
}
|
||||
}
|
||||
|
||||
if ((opt = expand(sizeof(struct prefix_opt))))
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user