examples/l2fwd-keepalive: fix memory leak
Fixes memory leaks detected by Coverity. These are due to ephemeral memory allocations not being freed when errors occur. Coverity issue: 127349 Fixes: e2aae1c1ced9 ("ethdev: remove name from extended statistic fetch") Signed-off-by: Remy Horton <remy.horton@intel.com>
This commit is contained in:
parent
21b5bd0d66
commit
9f2bb5ce8a
@ -80,6 +80,8 @@ struct rte_keepalive_shm *rte_keepalive_shm_create(void)
|
||||
RTE_LOG(INFO, EAL,
|
||||
"Failed to setup SHM semaphore (%s)\n",
|
||||
strerror(errno));
|
||||
munmap(ka_shm,
|
||||
sizeof(struct rte_keepalive_shm));
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user