aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVictor Goldenshtein <victorg@ti.com>2012-11-13 10:06:24 +0200
committerArik Nemtsov <arik@wizery.com>2012-11-13 10:17:27 +0200
commitf63238165abfda18b46bbc8c2a0e91aca853da64 (patch)
tree7c51a349ff8a9187974dd77e019fb4d84f50b56f
parent865eb5dc1f399c493a002a0f221f23c96799ed65 (diff)
downloadexternal_wpa_supplicant_8_ti-f63238165abfda18b46bbc8c2a0e91aca853da64.zip
external_wpa_supplicant_8_ti-f63238165abfda18b46bbc8c2a0e91aca853da64.tar.gz
external_wpa_supplicant_8_ti-f63238165abfda18b46bbc8c2a0e91aca853da64.tar.bz2
wpa_s: don't accumulate delayed sched scan requests (UPSTREAM)
Clear any previous pending timeouts before scheduling a new delayed sched scan. Signed-off-by: Victor Goldenshtein <victorg@ti.com>
-rw-r--r--wpa_supplicant/scan.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/wpa_supplicant/scan.c b/wpa_supplicant/scan.c
index e50dcfc..887c747 100644
--- a/wpa_supplicant/scan.c
+++ b/wpa_supplicant/scan.c
@@ -799,6 +799,9 @@ int wpa_supplicant_delayed_sched_scan(struct wpa_supplicant *wpa_s,
if (!wpa_s->sched_scan_supported)
return -1;
+ eloop_cancel_timeout(wpa_supplicant_delayed_sched_scan_timeout,
+ wpa_s, NULL);
+
eloop_register_timeout(sec, usec,
wpa_supplicant_delayed_sched_scan_timeout,
wpa_s, NULL);