summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
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);