mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-11 16:39:33 +00:00
ospf6d: solve segfaults with ospf6d on FreeBSD
Do not send ospf6d hellos on fresh created interfaces without configuration (ie. no vlan configured). Ospf6d use ip6_mtu, if it's not initalised, Ospf6d tries to alloc indefinite size of memory. Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
This commit is contained in:
parent
e708ed69aa
commit
1db65fadf6
@ -1721,6 +1721,13 @@ ospf6_hello_send (struct thread *thread)
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (iobuflen == 0)
|
||||||
|
{
|
||||||
|
zlog_debug ("Unable to send Hello on interface %s iobuflen is 0",
|
||||||
|
oi->interface->name);
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
/* set next thread */
|
/* set next thread */
|
||||||
oi->thread_send_hello = thread_add_timer (master, ospf6_hello_send,
|
oi->thread_send_hello = thread_add_timer (master, ospf6_hello_send,
|
||||||
oi, oi->hello_interval);
|
oi, oi->hello_interval);
|
||||||
|
@ -299,6 +299,7 @@ ifan_read (struct if_announcemsghdr *ifan)
|
|||||||
sizeof(ifan->ifan_name)));
|
sizeof(ifan->ifan_name)));
|
||||||
ifp->ifindex = ifan->ifan_index;
|
ifp->ifindex = ifan->ifan_index;
|
||||||
|
|
||||||
|
if_get_metric (ifp);
|
||||||
if_add_update (ifp);
|
if_add_update (ifp);
|
||||||
}
|
}
|
||||||
else if (ifp != NULL && ifan->ifan_what == IFAN_DEPARTURE)
|
else if (ifp != NULL && ifan->ifan_what == IFAN_DEPARTURE)
|
||||||
|
Loading…
Reference in New Issue
Block a user