Fixing uninitialized value access. Coverity issue: 414934 Fixes: 9a9eb104edf6 ("ethdev: parse multiple representor devargs")
Signed-off-by: Harman Kalra <hka...@marvell.com> --- lib/ethdev/ethdev_driver.c | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/ethdev/ethdev_driver.c b/lib/ethdev/ethdev_driver.c index aecb407c05..1660dd3f2a 100644 --- a/lib/ethdev/ethdev_driver.c +++ b/lib/ethdev/ethdev_driver.c @@ -546,6 +546,7 @@ eth_dev_tokenise_representor_list(char *p_val, struct rte_eth_devargs *eth_devar } memset(str, 0, BUFSIZ); + memset(da_val, 0, BUFSIZ); /* Remove the exterior [] of the consolidated list */ strncpy(str, &p_val[1], len - 2); while (1) { -- 2.18.0