summaryrefslogtreecommitdiff
path: root/examples/vm_power_manager
diff options
context:
space:
mode:
authorStephen Hemminger <stephen@networkplumber.org>2015-04-07 14:21:00 -0700
committerThomas Monjalon <thomas.monjalon@6wind.com>2015-04-13 22:50:10 +0200
commit176582b8a4868822b4e827a63af3db169fe03d4a (patch)
tree4891ddf36ae7eda8872def89f8ae2fcaf46b291d /examples/vm_power_manager
parent517f8377106cefb8d5b49a85ef4b1c3b86dc0466 (diff)
downloaddpdk-176582b8a4868822b4e827a63af3db169fe03d4a.zip
dpdk-176582b8a4868822b4e827a63af3db169fe03d4a.tar.gz
dpdk-176582b8a4868822b4e827a63af3db169fe03d4a.tar.xz
examples: remove useless null checks before rte_free
rte_free handles getting passed a NULL pointer. Signed-off-by: Stephen Hemminger <stephen@networkplumber.org> Acked-by: Neil Horman <nhorman@tuxdriver.com>
Diffstat (limited to 'examples/vm_power_manager')
-rw-r--r--examples/vm_power_manager/channel_manager.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/examples/vm_power_manager/channel_manager.c b/examples/vm_power_manager/channel_manager.c
index 04344ae..7d892e2 100644
--- a/examples/vm_power_manager/channel_manager.c
+++ b/examples/vm_power_manager/channel_manager.c
@@ -800,9 +800,7 @@ channel_manager_exit(void)
rte_free(vm_info);
}
- if (global_cpumaps != NULL)
- rte_free(global_cpumaps);
- if (global_vircpuinfo != NULL)
- rte_free(global_vircpuinfo);
+ rte_free(global_cpumaps);
+ rte_free(global_vircpuinfo);
disconnect_hypervisor();
}