From 8139b6bad7b1408d7547079b50e3cff6cdcc5d32 Mon Sep 17 00:00:00 2001 From: Denis Kenzior Date: Mon, 8 Feb 2021 14:12:12 -0600 Subject: [PATCH] unit: Drop un-needed null checks both ap_sm and sta_sm are passed to eapol_register and eapol_start. No need to check for null here --- unit/test-eapol.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/unit/test-eapol.c b/unit/test-eapol.c index eba249ed..b6a6adcb 100644 --- a/unit/test-eapol.c +++ b/unit/test-eapol.c @@ -3589,11 +3589,8 @@ static void test_ap_sta_run(struct test_ap_sta_data *s) s->to_sta_data, len, false); } - if (s->ap_sm) - eapol_sm_free(s->ap_sm); - - if (s->sta_sm) - eapol_sm_free(s->sta_sm); + eapol_sm_free(s->ap_sm); + eapol_sm_free(s->sta_sm); eapol_exit(); eap_exit();