From b98edbccf8ab5abf05d334e10328898223ae4263 Mon Sep 17 00:00:00 2001 From: Quentin Young Date: Sun, 1 Mar 2020 17:43:53 -0500 Subject: [PATCH] lib: ensure iface name is null terminated Signed-off-by: Quentin Young --- lib/zclient.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/zclient.c b/lib/zclient.c index 673e71c515..ba4070ffee 100644 --- a/lib/zclient.c +++ b/lib/zclient.c @@ -1756,7 +1756,7 @@ static void zclient_vrf_delete(struct zclient *zclient, vrf_id_t vrf_id) static int zclient_interface_add(struct zclient *zclient, vrf_id_t vrf_id) { struct interface *ifp; - char ifname_tmp[INTERFACE_NAMSIZ]; + char ifname_tmp[INTERFACE_NAMSIZ + 1] = {}; struct stream *s = zclient->ibuf; /* Read interface name. */ -- 2.39.5