summaryrefslogtreecommitdiff
path: root/pathd
diff options
context:
space:
mode:
Diffstat (limited to 'pathd')
-rw-r--r--pathd/path_zebra.c6
-rw-r--r--pathd/path_zebra.h1
-rw-r--r--pathd/pathd.c2
3 files changed, 9 insertions, 0 deletions
diff --git a/pathd/path_zebra.c b/pathd/path_zebra.c
index 156267a394..a98532cc39 100644
--- a/pathd/path_zebra.c
+++ b/pathd/path_zebra.c
@@ -352,3 +352,9 @@ void path_zebra_init(struct thread_master *master)
/* Connect to the LM. */
path_zebra_label_manager_connect();
}
+
+void path_zebra_stop(void)
+{
+ zclient_stop(zclient);
+ zclient_free(zclient);
+}
diff --git a/pathd/path_zebra.h b/pathd/path_zebra.h
index 42a7123dd4..683fcf10f7 100644
--- a/pathd/path_zebra.h
+++ b/pathd/path_zebra.h
@@ -30,5 +30,6 @@ void path_zebra_delete_sr_policy(struct srte_policy *policy);
int path_zebra_request_label(mpls_label_t label);
void path_zebra_release_label(mpls_label_t label);
void path_zebra_init(struct thread_master *master);
+void path_zebra_stop(void);
#endif /* _FRR_PATH_MPLS_H_ */
diff --git a/pathd/pathd.c b/pathd/pathd.c
index be2cfe8b01..e9d7cc6fc7 100644
--- a/pathd/pathd.c
+++ b/pathd/pathd.c
@@ -510,6 +510,8 @@ void srte_clean_zebra(void)
RB_FOREACH_SAFE (policy, srte_policy_head, &srte_policies, safe_pol)
srte_policy_del(policy);
+
+ path_zebra_stop();
}
/**