]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
FT: Check session_timeout pointer consistently
authorJouni Malinen <jouni@codeaurora.org>
Fri, 30 Nov 2018 19:07:19 +0000 (21:07 +0200)
committerJouni Malinen <j@w1.fi>
Fri, 30 Nov 2018 19:28:19 +0000 (21:28 +0200)
Avoid smatch warning on this even thought the only caller of the
function uses a non-NULL pointer in all cases.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
src/ap/wpa_auth_ft.c

index e8d46ab0dbb3f290820280a93d05219295ef27d3..f6792e00f32d80b029bc438d6e57e9e229b74dd3 100644 (file)
@@ -1451,7 +1451,7 @@ static int wpa_ft_fetch_pmk_r1(struct wpa_authenticator *wpa_auth,
                                        now.sec;
                        else if (session_timeout && r1->session_timeout)
                                *session_timeout = 1;
-                       else
+                       else if (session_timeout)
                                *session_timeout = 0;
                        return 0;
                }