wpa_supplicant : Fix invalid de-init of last_scan_res_used

During the wifi deinit last_scan_res_used pointer is not set to 0 which will cause it be used directly after reinit.

Added changes which will set it to 0 during init and deinit.
pull/10984/head
jgujarathi 2023-02-01 12:43:31 +05:30
rodzic 4b77473982
commit d23c21bd2a
1 zmienionych plików z 2 dodań i 0 usunięć

Wyświetl plik

@ -90,6 +90,7 @@ void esp_scan_init(struct wpa_supplicant *wpa_s)
wpa_s->scanning = 0;
wpa_bss_init(wpa_s);
wpa_s->last_scan_res = NULL;
wpa_s->last_scan_res_used = 0;
}
void esp_scan_deinit(struct wpa_supplicant *wpa_s)
@ -97,6 +98,7 @@ void esp_scan_deinit(struct wpa_supplicant *wpa_s)
wpa_bss_deinit(wpa_s);
os_free(wpa_s->last_scan_res);
wpa_s->last_scan_res = NULL;
wpa_s->last_scan_res_used = 0;
}
int esp_handle_beacon_probe(u8 type, u8 *frame, size_t len, u8 *sender,