mesh: Avoid join if already joined a mesh group

Signed-off-by: Javier Lopez <jlopex@gmail.com>
Signed-off-by: Thomas Pedersen <thomas@noack.us>
This commit is contained in:
Thomas Pedersen 2014-09-01 00:23:24 -04:00 committed by Jouni Malinen
parent 5f92659d88
commit a3335ef518

View file

@ -1382,6 +1382,13 @@ static int wpas_select_network_from_last_scan(struct wpa_supplicant *wpa_s,
*/
return 1;
} else {
#ifdef CONFIG_MESH
if (wpa_s->ifmsh) {
wpa_msg(wpa_s, MSG_INFO,
"Avoiding join because we already joined a mesh group");
return 0;
}
#endif /* CONFIG_MESH */
wpa_dbg(wpa_s, MSG_DEBUG, "No suitable network found");
ssid = wpa_supplicant_pick_new_network(wpa_s);
if (ssid) {