summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRenato Westphal <renato@openbsd.org>2017-05-12 12:51:06 -0300
committerGitHub <noreply@github.com>2017-05-12 12:51:06 -0300
commit51cd5cc35efb452b7d8b1775df2077d8eb8f36b4 (patch)
tree897dcdcbd295bd2e76f97f4526561c9283085777
parent05910d59385d33eb1a36198f359474c214e23091 (diff)
parent71e04b9f7ce518f0e7e33909f79b1d975a6421c8 (diff)
Merge pull request #518 from dwalton76/zebra-mpls-lsp-uninstall
zebra: zebra_mpls_lsp_uninstall was not being called
-rw-r--r--zebra/zebra_rib.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/zebra/zebra_rib.c b/zebra/zebra_rib.c
index e4d583d5f2..07b19155e2 100644
--- a/zebra/zebra_rib.c
+++ b/zebra/zebra_rib.c
@@ -1382,6 +1382,11 @@ rib_process_update_fib (struct zebra_vrf *zvrf, struct route_node *rn,
zlog_debug ("%u:%s: Updating route rn %p, rib %p (type %d)",
zvrf_id (zvrf), buf, rn, new, new->type);
}
+
+ /* If labeled-unicast route, uninstall transit LSP. */
+ if (zebra_rib_labeled_unicast (old))
+ zebra_mpls_lsp_uninstall (zvrf, rn, old);
+
/* Non-system route should be installed. */
if (!RIB_SYSTEM_ROUTE (new))
{
@@ -1403,10 +1408,6 @@ rib_process_update_fib (struct zebra_vrf *zvrf, struct route_node *rn,
{
if (RIB_SYSTEM_ROUTE(new))
{
- /* If labeled-unicast route, uninstall transit LSP. */
- if (zebra_rib_labeled_unicast (old))
- zebra_mpls_lsp_uninstall (zvrf, rn, old);
-
if (!RIB_SYSTEM_ROUTE (old))
rib_uninstall_kernel (rn, old);
}