summaryrefslogtreecommitdiff
path: root/ospfd/ospf_asbr.c
diff options
context:
space:
mode:
Diffstat (limited to 'ospfd/ospf_asbr.c')
-rw-r--r--ospfd/ospf_asbr.c22
1 files changed, 12 insertions, 10 deletions
diff --git a/ospfd/ospf_asbr.c b/ospfd/ospf_asbr.c
index 1b68f6e022..9b62f36d7a 100644
--- a/ospfd/ospf_asbr.c
+++ b/ospfd/ospf_asbr.c
@@ -110,7 +110,8 @@ ospf_external_info_add(struct ospf *ospf, uint8_t type, unsigned short instance,
new = rn->info;
if ((new->ifindex == ifindex)
&& (new->nexthop.s_addr == nexthop.s_addr)
- && (new->tag == tag)) {
+ && (new->tag == tag)
+ && (new->metric == metric)) {
route_unlock_node(rn);
return NULL; /* NULL => no LSA to refresh */
}
@@ -265,17 +266,17 @@ void ospf_asbr_status_update(struct ospf *ospf, uint8_t status)
}
/* If there's redistribution configured, we need to refresh external
- * LSAs in order to install Type-7 and flood to all NSSA Areas
+ * LSAs (e.g. when default-metric changes or NSSA settings change).
*/
-static void ospf_asbr_nssa_redist_update_timer(struct event *thread)
+static void ospf_asbr_redist_update_timer(struct event *thread)
{
struct ospf *ospf = EVENT_ARG(thread);
int type;
- ospf->t_asbr_nssa_redist_update = NULL;
+ ospf->t_asbr_redist_update = NULL;
if (IS_DEBUG_OSPF_EVENT)
- zlog_debug("Running ASBR NSSA redistribution update on timer");
+ zlog_debug("Running ASBR redistribution update on timer");
for (type = 0; type < ZEBRA_ROUTE_MAX; type++) {
struct list *red_list;
@@ -295,14 +296,14 @@ static void ospf_asbr_nssa_redist_update_timer(struct event *thread)
ospf_external_lsa_refresh_default(ospf);
}
-void ospf_schedule_asbr_nssa_redist_update(struct ospf *ospf)
+void ospf_schedule_asbr_redist_update(struct ospf *ospf)
{
if (IS_DEBUG_OSPF_EVENT)
- zlog_debug("Scheduling ASBR NSSA redistribution update");
+ zlog_debug("Scheduling ASBR redistribution update");
- event_add_timer(master, ospf_asbr_nssa_redist_update_timer, ospf,
- OSPF_ASBR_NSSA_REDIST_UPDATE_DELAY,
- &ospf->t_asbr_nssa_redist_update);
+ event_add_timer(master, ospf_asbr_redist_update_timer, ospf,
+ OSPF_ASBR_REDIST_UPDATE_DELAY,
+ &ospf->t_asbr_redist_update);
}
void ospf_redistribute_withdraw(struct ospf *ospf, uint8_t type,
@@ -987,6 +988,7 @@ static void ospf_handle_external_aggr_update(struct ospf *ospf)
&aggr->match_extnl_hash,
(void *)ospf_aggr_handle_external_info);
+ ospf_external_aggregator_free(aggr);
} else if (aggr->action == OSPF_ROUTE_AGGR_MODIFY) {
aggr->action = OSPF_ROUTE_AGGR_NONE;