summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorMark Stapp <mjs@voltanet.io>2020-03-12 14:45:55 +0100
committerGitHub <noreply@github.com>2020-03-12 14:45:55 +0100
commit864aa5a1ccc82e9b85ee52fd71e39b1d08f76b27 (patch)
tree7546cad11aa1e001ff2627a8a80d25b9717ea000 /lib
parentMerge pull request #5974 from donaldsharp/ldp_ifindex_missed (diff)
parent*: Remove tests for some XFREE-family functions (diff)
downloadfrr-864aa5a1ccc82e9b85ee52fd71e39b1d08f76b27.tar.xz
frr-864aa5a1ccc82e9b85ee52fd71e39b1d08f76b27.zip
Merge pull request #5981 from ton31337/fix/not_necessary_checks
*: Remove tests for some XFREE-family functions
Diffstat (limited to 'lib')
-rw-r--r--lib/if.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/lib/if.c b/lib/if.c
index 5edb58a2d..dabf66799 100644
--- a/lib/if.c
+++ b/lib/if.c
@@ -887,11 +887,8 @@ void connected_free(struct connected **connected)
{
struct connected *ptr = *connected;
- if (ptr->address)
- prefix_free(&ptr->address);
-
- if (ptr->destination)
- prefix_free(&ptr->destination);
+ prefix_free(&ptr->address);
+ prefix_free(&ptr->destination);
XFREE(MTYPE_CONNECTED_LABEL, ptr->label);