mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-05-02 16:57:25 +00:00
lib: remove null check before free nh_labels
Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
This commit is contained in:
parent
ce1234aa0b
commit
fe86c6b3b1
@ -415,10 +415,8 @@ void nexthop_add_labels(struct nexthop *nexthop, enum lsp_types_t type,
|
||||
/* Free label information of nexthop, if present. */
|
||||
void nexthop_del_labels(struct nexthop *nexthop)
|
||||
{
|
||||
if (nexthop->nh_label) {
|
||||
XFREE(MTYPE_NH_LABEL, nexthop->nh_label);
|
||||
nexthop->nh_label_type = ZEBRA_LSP_NONE;
|
||||
}
|
||||
XFREE(MTYPE_NH_LABEL, nexthop->nh_label);
|
||||
nexthop->nh_label_type = ZEBRA_LSP_NONE;
|
||||
}
|
||||
|
||||
const char *nexthop2str(const struct nexthop *nexthop, char *str, int size)
|
||||
|
Loading…
Reference in New Issue
Block a user