[PATCH] CONFIG_AP: Run time reconfiguration fix
Bartosz.Markowski at tieto.com
Bartosz.Markowski
Tue Apr 12 00:08:13 PDT 2011
Hi,
Is this patch not correct?
It makes life easier in case you want to reconfigure AP in run time.
/Bartosz
-----Original Message-----
From: hostap-bounces at lists.shmoo.com [mailto:hostap-bounces at lists.shmoo.com] On Behalf Of Bartosz.Markowski at tieto.com
Sent: 1 kwietnia 2011 15:17
To: hostap at lists.shmoo.com
Subject: [PATCH] CONFIG_AP: Run time reconfiguration fix
Hi,
Small patch for CONFIG_AP mode - run time reconfiguration of AP.
When receiving DISABLE_NETWORK/REMOVE_NETWORK ap_deinit was not called.
When ssid->mode is WAPS_MODE_AP, call wpa_supplicant_ap_deinit() and reset reassociated_connection flag.
---
wpa_supplicant/ctrl_iface.c | 13 +++++++++++++
1 files changed, 13 insertions(+), 0 deletions(-)
diff --git a/wpa_supplicant/ctrl_iface.c b/wpa_supplicant/ctrl_iface.c
index 5488ea4..43d6dc5 100644
--- a/wpa_supplicant/ctrl_iface.c
+++ b/wpa_supplicant/ctrl_iface.c
@@ -1341,6 +1341,13 @@ static int wpa_supplicant_ctrl_iface_disable_network(
}
wpa_supplicant_disable_network(wpa_s, ssid);
+#ifdef CONFIG_AP
+ if (ssid->mode == WPAS_MODE_AP) {
+ wpa_supplicant_ap_deinit(wpa_s);
+ wpa_s->reassociated_connection = 0;
+ }
+#endif
+
return 0;
}
@@ -1415,6 +1422,12 @@ static int wpa_supplicant_ctrl_iface_remove_network(
wpa_supplicant_disassociate(wpa_s, WLAN_REASON_DEAUTH_LEAVING);
}
+#ifdef CONFIG_AP
+ if (ssid->mode == WPAS_MODE_AP) {
+ wpa_supplicant_ap_deinit(wpa_s);
+ wpa_s->reassociated_connection = 0;
+ }
+#endif
return 0;
}
Best Regards,
Bartosz Markowski
_______________________________________________
HostAP mailing list
HostAP at lists.shmoo.com
http://lists.shmoo.com/mailman/listinfo/hostap
More information about the Hostap
mailing list