Coverity issue: 380976
Fixes: e3be2495 ("net/softnic: add pipeline code generation command")Fix file close at pipeline code generation. Signed-off-by: Harshad Narayane <[email protected]> Signed-off-by: Kamalakannan R <[email protected]> Acked-by: Cristian Dumitrescu <[email protected]> --- drivers/net/softnic/rte_eth_softnic_cli.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/net/softnic/rte_eth_softnic_cli.c b/drivers/net/softnic/rte_eth_softnic_cli.c index 7891f2b24f..e46383352b 100644 --- a/drivers/net/softnic/rte_eth_softnic_cli.c +++ b/drivers/net/softnic/rte_eth_softnic_cli.c @@ -230,6 +230,7 @@ cmd_softnic_pipeline_codegen(struct pmd_internals *softnic __rte_unused, code_file = fopen(tokens[3], "w"); if (!code_file) { snprintf(out, out_size, "Cannot open file %s.\n", tokens[3]); + fclose(spec_file); return; } -- 2.25.1

