Skip to content

Commit

Permalink
Merge pull request FRRouting#3298 from ak503/mpls_te2
Browse files Browse the repository at this point in the history
ospfd: unregister mpls-te inter-as only if mpls-te is enabled
  • Loading branch information
odd22 committed Nov 9, 2018
2 parents ddd73a9 + e790de4 commit 3759776
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions ospfd/ospf_te.c
Original file line number Diff line number Diff line change
Expand Up @@ -2398,16 +2398,16 @@ DEFUN (no_ospf_mpls_te_inter_as,
zlog_debug("MPLS-TE: Inter-AS support OFF");

if ((OspfMplsTE.enabled) && (OspfMplsTE.inter_as != Off)) {
OspfMplsTE.inter_as = Off;
/* Flush all Inter-AS LSA */
for (ALL_LIST_ELEMENTS(OspfMplsTE.iflist, node, nnode, lp))
if (IS_INTER_AS(lp->type)
&& CHECK_FLAG(lp->flags, LPFLG_LSA_ENGAGED))
ospf_mpls_te_lsa_schedule(lp, FLUSH_THIS_LSA);
}

/* Deregister the Callbacks for Inter-AS support */
ospf_mpls_te_unregister();
/* Deregister the Callbacks for Inter-AS support */
ospf_mpls_te_unregister();
OspfMplsTE.inter_as = Off;
}

return CMD_SUCCESS;
}
Expand Down

0 comments on commit 3759776

Please sign in to comment.