]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
bgscan: Stop bgscan only on disassociation
authorEliad Peller <eliad@wizery.com>
Thu, 19 Dec 2013 10:03:23 +0000 (12:03 +0200)
committerJouni Malinen <j@w1.fi>
Tue, 24 Dec 2013 04:48:28 +0000 (06:48 +0200)
Stopping bgscan on any state other than COMPLETED results
in bgscan reset (stop + start) on every rekeying operation.

Signed-hostap: Eliad Peller <eliad@wizery.com>

wpa_supplicant/wpa_supplicant.c

index 6f1137a8f14914c275324b1d29f138e6881d2d9e..6390d130c88dfe22c5e9b3d9e667e3e8a0ce0709 100644 (file)
@@ -699,7 +699,7 @@ void wpa_supplicant_set_state(struct wpa_supplicant *wpa_s,
 #ifdef CONFIG_BGSCAN
        if (state == WPA_COMPLETED)
                wpa_supplicant_start_bgscan(wpa_s);
-       else
+       else if (state < WPA_ASSOCIATED)
                wpa_supplicant_stop_bgscan(wpa_s);
 #endif /* CONFIG_BGSCAN */