eal: fix leak on device event callback unregister
authorYunjian Wang <wangyunjian@huawei.com>
Wed, 21 Oct 2020 11:19:03 +0000 (19:19 +0800)
committerDavid Marchand <david.marchand@redhat.com>
Fri, 23 Oct 2020 11:35:48 +0000 (13:35 +0200)
commitc78bd27d4b74a74261b180cb8d5421b919c1ab9a
tree22583bc1ad8b36c35cddc13beec9e884e81e9294
parent4054466be9c64e72c37cffd840ab0f35a946a867
eal: fix leak on device event callback unregister

The event_cb->dev_name is not freed when freeing event_cb,
and this causes a memory leak.

Fixes: a753e53d517b ("eal: add device event monitor framework")
Cc: stable@dpdk.org
Signed-off-by: Yunjian Wang <wangyunjian@huawei.com>
Acked-by: Jeff Guo <jia.guo@intel.com>
Acked-by: David Marchand <david.marchand@redhat.com>
lib/librte_eal/common/eal_common_dev.c