diff options
| author | Quentin Young <qlyoung@cumulusnetworks.com> | 2019-02-25 20:18:13 +0000 |
|---|---|---|
| committer | Quentin Young <qlyoung@cumulusnetworks.com> | 2019-02-25 23:00:46 +0000 |
| commit | 0a22ddfbb16a61c3e068ea1164e885104366112a (patch) | |
| tree | 5aeaef43b3de5ebbdfcf1015421eb48b51a071fb /lib/nexthop_group.c | |
| parent | 1383ff9c51dd58ed84021fafb14f7c2e27b7666b (diff) | |
*: remove null check before XFREE
Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
Diffstat (limited to 'lib/nexthop_group.c')
| -rw-r--r-- | lib/nexthop_group.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/lib/nexthop_group.c b/lib/nexthop_group.c index 23ea96f75c..f940418d83 100644 --- a/lib/nexthop_group.c +++ b/lib/nexthop_group.c @@ -205,11 +205,9 @@ static int nhgl_cmp(struct nexthop_hold *nh1, struct nexthop_hold *nh2) static void nhgl_delete(struct nexthop_hold *nh) { - if (nh->intf) - XFREE(MTYPE_TMP, nh->intf); + XFREE(MTYPE_TMP, nh->intf); - if (nh->nhvrf_name) - XFREE(MTYPE_TMP, nh->nhvrf_name); + XFREE(MTYPE_TMP, nh->nhvrf_name); XFREE(MTYPE_TMP, nh); } |
