From 9977609b7ae4412d5c69303acda387a4f623fdde Mon Sep 17 00:00:00 2001 From: Thomas Haller Date: Thu, 2 Feb 2017 22:30:37 +0100 Subject: [PATCH] device/wifi: first emit NEW_BSS signals before SCAN_DONE In the SCAN_DONE handler, NMDeviceWifi resets the flag that indicates that a current scan request is pending. We need to first obtain the new APs (NEW_BSS) before signalling SCAN_DONE. (cherry picked from commit 40a4cc5b2dcb2de6643ac36ff6efd0a1262093f5) --- src/supplicant/nm-supplicant-interface.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/supplicant/nm-supplicant-interface.c b/src/supplicant/nm-supplicant-interface.c index 8bed7eed4c..2698b74f7e 100644 --- a/src/supplicant/nm-supplicant-interface.c +++ b/src/supplicant/nm-supplicant-interface.c @@ -562,8 +562,6 @@ wpas_iface_scan_done (GDBusProxy *proxy, /* Cache last scan completed time */ priv->last_scan = nm_utils_get_monotonic_timestamp_s (); - g_signal_emit (self, signals[SCAN_DONE], 0, success); - /* Emit NEW_BSS so that wifi device has the APs (in case it removed them) */ g_hash_table_iter_init (&iter, priv->bss_proxies); while (g_hash_table_iter_next (&iter, (gpointer) &bss_path, (gpointer) &bss_proxy)) { @@ -577,6 +575,8 @@ wpas_iface_scan_done (GDBusProxy *proxy, } } } + + g_signal_emit (self, signals[SCAN_DONE], 0, success); } static void