summaryrefslogtreecommitdiffstats
path: root/ospfd
diff options
context:
space:
mode:
authorDavid Lamparter <equinox@diac24.net>2010-02-04 02:17:04 +0100
committerDavid Lamparter <equinox@diac24.net>2010-02-04 02:17:04 +0100
commitaadbf3af3385d9bd394beafa17aa1a50c6141dfc (patch)
tree3f94bca73b9fa8801498f27451a1c1215d38afaa /ospfd
parentf65b8886cc94cce3afef3e199b538a4263947f09 (diff)
downloadquagga-aadbf3af3385d9bd394beafa17aa1a50c6141dfc.tar.bz2
quagga-aadbf3af3385d9bd394beafa17aa1a50c6141dfc.tar.xz
ospfd: fix opaque-LSA broken by route_node -> list
ospf_opaque.c needs to be updated for moving from route_node to a regular list.
Diffstat (limited to 'ospfd')
-rw-r--r--ospfd/ospf_opaque.c21
1 files changed, 9 insertions, 12 deletions
diff --git a/ospfd/ospf_opaque.c b/ospfd/ospf_opaque.c
index 0b6ac4cb..826d149f 100644
--- a/ospfd/ospf_opaque.c
+++ b/ospfd/ospf_opaque.c
@@ -2118,11 +2118,12 @@ out:
* Followings are control functions to block origination after restart.
*------------------------------------------------------------------------*/
-static void ospf_opaque_exclude_lsa_from_lsreq (struct route_table *nbrs, struct ospf_neighbor *inbr, struct ospf_lsa *lsa);
+static void ospf_opaque_exclude_lsa_from_lsreq (struct list *nbrs,
+ struct ospf_neighbor *inbr, struct ospf_lsa *lsa);
static void ospf_opaque_type9_lsa_rxmt_nbr_check (struct ospf_interface *oi);
static void ospf_opaque_type10_lsa_rxmt_nbr_check (struct ospf_area *area);
static void ospf_opaque_type11_lsa_rxmt_nbr_check (struct ospf *top);
-static unsigned long ospf_opaque_nrxmt_self (struct route_table *nbrs, int lsa_type);
+static unsigned long ospf_opaque_nrxmt_self (struct list *nbrs, int lsa_type);
void
ospf_opaque_adjust_lsreq (struct ospf_neighbor *nbr, struct list *lsas)
@@ -2199,18 +2200,16 @@ out:
}
static void
-ospf_opaque_exclude_lsa_from_lsreq (struct route_table *nbrs,
+ospf_opaque_exclude_lsa_from_lsreq (struct list *nbrs,
struct ospf_neighbor *inbr,
struct ospf_lsa *lsa)
{
- struct route_node *rn;
+ struct listnode *node;
struct ospf_neighbor *onbr;
struct ospf_lsa *ls_req;
- for (rn = route_top (nbrs); rn; rn = route_next (rn))
+ for (ALL_LIST_ELEMENTS_RO (nbrs, node, onbr))
{
- if ((onbr = rn->info) == NULL)
- continue;
if (onbr == inbr)
continue;
if ((ls_req = ospf_ls_request_lookup (onbr, lsa)) == NULL)
@@ -2412,17 +2411,15 @@ out:
}
static unsigned long
-ospf_opaque_nrxmt_self (struct route_table *nbrs, int lsa_type)
+ospf_opaque_nrxmt_self (struct list *nbrs, int lsa_type)
{
- struct route_node *rn;
+ struct listnode *node;
struct ospf_neighbor *nbr;
struct ospf *top;
unsigned long n = 0;
- for (rn = route_top (nbrs); rn; rn = route_next (rn))
+ for (ALL_LIST_ELEMENTS_RO (nbrs, node, nbr))
{
- if ((nbr = rn->info) == NULL)
- continue;
if ((top = oi_to_top (nbr->oi)) == NULL)
continue;
if (IPV4_ADDR_SAME (&nbr->router_id, &top->router_id))