OSDN Git Service

Cumulative patch from commit b2b688d18d40cd667d0faa149b4a7172166b3bd4
[android-x86/external-wpa_supplicant_8.git] / wpa_supplicant / notify.c
index f2cbdd7..ab62bea 100644 (file)
@@ -226,7 +226,7 @@ void wpas_notify_network_added(struct wpa_supplicant *wpa_s,
         * applications since these network objects won't behave like
         * regular ones.
         */
-       if (wpa_s->global->p2p_group_formation != wpa_s)
+       if (!ssid->p2p_group && wpa_s->global->p2p_group_formation != wpa_s)
                wpas_dbus_register_network(wpa_s, ssid);
 }
 
@@ -254,7 +254,7 @@ void wpas_notify_network_removed(struct wpa_supplicant *wpa_s,
 {
        if (wpa_s->wpa)
                wpa_sm_pmksa_cache_flush(wpa_s->wpa, ssid);
-       if (wpa_s->global->p2p_group_formation != wpa_s)
+       if (!ssid->p2p_group && wpa_s->global->p2p_group_formation != wpa_s)
                wpas_dbus_unregister_network(wpa_s, ssid->id);
 #ifdef CONFIG_P2P
        wpas_p2p_network_removed(wpa_s, ssid);