Fixes broken multi-area OSPF.

This commit is contained in:
Ondrej Zajicek 2011-07-20 23:46:03 +02:00
parent c49490f8c0
commit 9008579b97

View file

@ -213,7 +213,7 @@ rt_pos_to_ifa(struct ospf_area *oa, int pos)
{ {
struct ospf_iface *ifa; struct ospf_iface *ifa;
WALK_LIST(ifa, oa->po->iface_list) WALK_LIST(ifa, oa->po->iface_list)
if (pos >= ifa->rt_pos_beg && pos < ifa->rt_pos_end) if (ifa->oa == oa && pos >= ifa->rt_pos_beg && pos < ifa->rt_pos_end)
return ifa; return ifa;
return NULL; return NULL;
} }
@ -224,7 +224,7 @@ px_pos_to_ifa(struct ospf_area *oa, int pos)
{ {
struct ospf_iface *ifa; struct ospf_iface *ifa;
WALK_LIST(ifa, oa->po->iface_list) WALK_LIST(ifa, oa->po->iface_list)
if (pos >= ifa->px_pos_beg && pos < ifa->px_pos_end) if (ifa->oa == oa && pos >= ifa->px_pos_beg && pos < ifa->px_pos_end)
return ifa; return ifa;
return NULL; return NULL;
} }