Commit cd3b02d1 authored by Ondřej Zajíček's avatar Ondřej Zajíček

Allows IP of loopback to be used in automatic router ID selection.

Thanks to Alexander V. Chernikov for the patch.
parent 8bd9b930
......@@ -589,7 +589,7 @@ if_choose_router_id(struct iface_patt *mask, u32 old_id)
WALK_LIST(i, iface_list)
if (!(i->flags & IF_ADMIN_UP) ||
(i->flags & (IF_IGNORE | IF_SHUTDOWN)))
(i->flags & IF_SHUTDOWN))
WALK_LIST(a, i->addrs)
......@@ -612,6 +612,10 @@ if_choose_router_id(struct iface_patt *mask, u32 old_id)
if (mask && !iface_patt_match(mask, i, a))
/* FIXME: This should go away too */
if ((i->flags & IF_IGNORE) && !mask)
/* No pattern or pattern matched */
if (!b || ipa_to_u32(a->ip) < ipa_to_u32(b->ip))
b = a;
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment