diff options
| -rw-r--r-- | lib/nexthop_group.c | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/lib/nexthop_group.c b/lib/nexthop_group.c index 23ea96f75c..57609b648f 100644 --- a/lib/nexthop_group.c +++ b/lib/nexthop_group.c @@ -322,13 +322,7 @@ static void nexthop_group_unsave_nhop(struct nexthop_group_cmd *nhgc, return; list_delete_node(nhgc->nhg_list, node); - - if (nh->nhvrf_name) - XFREE(MTYPE_TMP, nh->nhvrf_name); - if (nh->intf) - XFREE(MTYPE_TMP, nh->intf); - - XFREE(MTYPE_TMP, nh); + nhgl_delete(nh); } static bool nexthop_group_parse_nexthop(struct nexthop *nhop, |
