summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorDave Barach <dave@barachs.net>2019-05-14 08:12:36 -0400
committerFlorin Coras <florin.coras@gmail.com>2019-05-14 17:50:49 +0000
commita4ef82efee3d58ecda83f0982eff858252c51a90 (patch)
treeb60856be641e8a6c7c31b8eb8bf89d3707296dec /src
parent2180baccc1428ffbd64a8312f3c983791a0771ab (diff)
VPP-1649: fix coverity warning in api_format.c
Change-Id: Idc22377ca705a45300faaf8acbc3cae5f10e1c92 Signed-off-by: Dave Barach <dave@barachs.net>
Diffstat (limited to 'src')
-rw-r--r--src/vat/api_format.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/vat/api_format.c b/src/vat/api_format.c
index fb0f3fdbf1d..10e9d3e8593 100644
--- a/src/vat/api_format.c
+++ b/src/vat/api_format.c
@@ -2699,7 +2699,7 @@ vl_api_dhcp_compl_event_t_handler (vl_api_dhcp_compl_event_t * mp)
{
u8 *s, i;
- s = format (s, "DHCP compl event: pid %d %s hostname %s host_addr %U "
+ s = format (0, "DHCP compl event: pid %d %s hostname %s host_addr %U "
"host_mac %U router_addr %U",
ntohl (mp->pid), mp->lease.is_ipv6 ? "ipv6" : "ipv4",
mp->lease.hostname,
@@ -2713,6 +2713,7 @@ vl_api_dhcp_compl_event_t_handler (vl_api_dhcp_compl_event_t * mp)
mp->lease.domain_server[i].address);
errmsg ((char *) s);
+ vec_free (s);
}
static void vl_api_dhcp_compl_event_t_handler_json