summaryrefslogtreecommitdiff
path: root/pbrd/pbr_map.c
diff options
context:
space:
mode:
authorRuss White <russ@riw.us>2023-09-12 11:28:20 -0400
committerGitHub <noreply@github.com>2023-09-12 11:28:20 -0400
commit7159e93f478731bd91a57e0d7a9a4d74b9e2de6a (patch)
treeb9080397df49fbc44a648b47b77f6da3eb704b10 /pbrd/pbr_map.c
parentbf4e97c632538b6f79ff0a9ae738f2d12485c01c (diff)
parent0214fb7bfcc5af310d91351f4aa9fa95a402fd5f (diff)
Merge pull request #14237 from Keelan10/pbrd-map-leak
pbrd: Free Memory in pbr_map_delete
Diffstat (limited to 'pbrd/pbr_map.c')
-rw-r--r--pbrd/pbr_map.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/pbrd/pbr_map.c b/pbrd/pbr_map.c
index 774e7ee85a..8f7a46377c 100644
--- a/pbrd/pbr_map.c
+++ b/pbrd/pbr_map.c
@@ -357,6 +357,11 @@ extern void pbr_map_delete(struct pbr_map_sequence *pbrms)
if (pbrms->nhg)
pbr_nht_delete_individual_nexthop(pbrms);
+ if (pbrms->nhgrp_name)
+ XFREE(MTYPE_TMP, pbrms->nhgrp_name);
+
+ prefix_free(&pbrms->dst);
+
listnode_delete(pbrm->seqnumbers, pbrms);
if (pbrm->seqnumbers->count == 0) {