diff mbox series

[81/82] power: remove unnecessary NULL checks

Message ID 20220124000518.319850-82-stephen@networkplumber.org (mailing list archive)
State Superseded, archived
Delegated to: Thomas Monjalon
Headers show
Series remove unnecessary null checks | expand

Checks

Context Check Description
ci/checkpatch success coding style OK

Commit Message

Stephen Hemminger Jan. 24, 2022, 12:05 a.m. UTC
Remove redundant NULL pointer checks before free functions
found by nullfree.cocci

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
---
 lib/power/rte_power_empty_poll.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
diff mbox series

Patch

diff --git a/lib/power/rte_power_empty_poll.c b/lib/power/rte_power_empty_poll.c
index c4b5de9601cf..2261ce7820f6 100644
--- a/lib/power/rte_power_empty_poll.c
+++ b/lib/power/rte_power_empty_poll.c
@@ -457,8 +457,7 @@  rte_power_empty_poll_stat_free(void)
 
 	RTE_LOG(INFO, POWER, "Close the Empty Poll\n");
 
-	if (ep_params != NULL)
-		rte_free(ep_params);
+	rte_free(ep_params);
 }
 
 int