summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xplugins/wifi.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/plugins/wifi.c b/plugins/wifi.c
index db4f5bf7..6a1ca367 100755
--- a/plugins/wifi.c
+++ b/plugins/wifi.c
@@ -2616,6 +2616,14 @@ static void interface_state(GSupplicantInterface *interface)
wifi->assoc_retry_count = 0;
wifi->scan_pending_network = NULL;
+
+ /* should be cleared scanning flag */
+ bool scanning = connman_device_get_scanning(device);
+ if (scanning){
+ connman_device_set_scanning(device,
+ CONNMAN_SERVICE_TYPE_WIFI, false);
+ connman_device_unref(device);
+ }
#else
/* though it should be already stopped: */
stop_autoscan(device);