]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
Fix TX status processing during AP mode shutdown in wpa_supplicant
authorJouni Malinen <j@w1.fi>
Mon, 6 Jan 2014 15:54:16 +0000 (17:54 +0200)
committerJouni Malinen <j@w1.fi>
Tue, 7 Jan 2014 08:45:12 +0000 (10:45 +0200)
A TX status event could be received after the AP interface has already
been deinitialized. This needs to check for NULL pointer before trying
to indicate the event to AP functions.

Signed-hostap: Jouni Malinen <j@w1.fi>

wpa_supplicant/ap.c

index 412db23bcb09252848f8c35f8c87d46d1f600fea..ea4e6bba5e0f8f9d89f050b22f5cb957d47d13e4 100644 (file)
@@ -680,6 +680,8 @@ void ap_eapol_tx_status(void *ctx, const u8 *dst,
 {
 #ifdef NEED_AP_MLME
        struct wpa_supplicant *wpa_s = ctx;
+       if (!wpa_s->ap_iface)
+               return;
        hostapd_tx_status(wpa_s->ap_iface->bss[0], dst, data, len, ack);
 #endif /* NEED_AP_MLME */
 }