net/ring: remove unnecessary NULL check

Coverity detected this as an issue because internals->data will never be NULL,
then the check is not necessary.

Coverity issue: 137873
Fixes: d082c0395bf6 ("ring: fix memory leak when detaching")

Signed-off-by: Mauricio Vasquez B <mauricio.vasquez@polito.it>
Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
This commit is contained in:
Mauricio Vasquez B 2016-11-02 08:46:09 -05:00 committed by Thomas Monjalon
parent 25c62ca4eb
commit f74ea27bb5

View File

@ -599,7 +599,6 @@ rte_pmd_ring_remove(const char *name)
eth_dev_stop(eth_dev);
if (eth_dev->data) {
internals = eth_dev->data->dev_private;
if (internals->action == DEV_CREATE) {
/*
@ -615,7 +614,6 @@ rte_pmd_ring_remove(const char *name)
rte_free(eth_dev->data->rx_queues);
rte_free(eth_dev->data->tx_queues);
rte_free(eth_dev->data->dev_private);
}
rte_free(eth_dev->data);