From: Nigel Kukard Date: Fri, 1 Sep 2017 02:01:55 +0000 (+0000) Subject: bgpd: Use lcommunity_new() to allocate new lcommunity X-Git-Tag: frr-4.0-dev~348^2~3 X-Git-Url: https://git.puffer.fish/?a=commitdiff_plain;h=cb0c2da3a885d569d1db0092b5d19bb83d7d0cc0;p=matthieu%2Ffrr.git bgpd: Use lcommunity_new() to allocate new lcommunity Signed-off-by: Nigel Kukard --- diff --git a/bgpd/bgp_lcommunity.c b/bgpd/bgp_lcommunity.c index f464e7122d..ad7cb36afe 100644 --- a/bgpd/bgp_lcommunity.c +++ b/bgpd/bgp_lcommunity.c @@ -148,7 +148,7 @@ struct lcommunity *lcommunity_dup(struct lcommunity *lcom) { struct lcommunity *new; - new = XCALLOC(MTYPE_LCOMMUNITY, sizeof(struct lcommunity)); + new = lcommunity_new(); new->size = lcom->size; if (new->size) { new->val = XMALLOC(MTYPE_LCOMMUNITY_VAL, lcom_length(lcom));