mka: Simplify ieee802_1x_mka_dist_sak_body_present()
authorSabrina Dubroca <sd@queasysnail.net>
Mon, 15 Aug 2016 09:43:42 +0000 (11:43 +0200)
committerJouni Malinen <j@w1.fi>
Sun, 28 Aug 2016 18:17:43 +0000 (21:17 +0300)
No need for an if statement to figure out Boolean return value.

Signed-off-by: Sabrina Dubroca <sd@queasysnail.net>
src/pae/ieee802_1x_kay.c

index d29187d..88fb9ce 100644 (file)
@@ -1395,10 +1395,7 @@ static Boolean
 ieee802_1x_mka_dist_sak_body_present(
        struct ieee802_1x_mka_participant *participant)
 {
-       if (!participant->to_dist_sak || !participant->new_key)
-               return FALSE;
-
-       return TRUE;
+       return participant->to_dist_sak && participant->new_key;
 }