Fix scan rescheduling from wpas_stop_pno to check postponed case
authorJouni Malinen <jouni@qca.qualcomm.com>
Thu, 3 Mar 2016 09:04:38 +0000 (11:04 +0200)
committerJouni Malinen <j@w1.fi>
Thu, 3 Mar 2016 09:04:38 +0000 (11:04 +0200)
commitbef5e9a8620128a23c32d4253099b1449d4864aa
treea9d3263eba17e5b15684fe4808aa96dfe1a78fbc
parent29b508e7dc7df01cf99474afcd36d3cbba281db9
Fix scan rescheduling from wpas_stop_pno to check postponed case

Commit 02e122a995dea947a2ad2c0d85190d709f9128b7 ('Reschedule scan from
wpas_stop_pno if it was postponed') uses wpa_s->scanning as the only
condition for automatically starting a postponed scan request from
EVENT_SCHED_SCAN_STOPPED event handler. However, wpa_s->scanning may be
set for sched_scan and as such, this can result in unexpected extra
scans without there having been any real postponed request.

Make this more accurate by verifying that there really is a pending
request for a scan before speeding up its start.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
wpa_supplicant/events.c