2011-04-19 18:41:49 +03:00
|
|
|
--- a/src/drivers/driver_nl80211.c
|
|
|
|
+++ b/src/drivers/driver_nl80211.c
|
2011-05-28 19:27:12 +03:00
|
|
|
@@ -5660,6 +5660,9 @@ static int i802_set_wds_sta(void *priv,
|
2011-04-19 18:41:49 +03:00
|
|
|
linux_set_iface_flags(drv->ioctl_sock, name, 1);
|
|
|
|
return i802_set_sta_vlan(priv, addr, name, 0);
|
|
|
|
} else {
|
|
|
|
+ if (bridge_ifname)
|
|
|
|
+ linux_br_del_if(drv->ioctl_sock, bridge_ifname, name);
|
|
|
|
+
|
|
|
|
i802_set_sta_vlan(priv, addr, bss->ifname, 0);
|
|
|
|
return wpa_driver_nl80211_if_remove(priv, WPA_IF_AP_VLAN,
|
|
|
|
name);
|
2011-05-28 19:27:12 +03:00
|
|
|
@@ -6021,14 +6024,14 @@ static int wpa_driver_nl80211_if_remove(
|
2011-04-19 18:41:49 +03:00
|
|
|
return -1;
|
|
|
|
|
|
|
|
#ifdef HOSTAPD
|
|
|
|
- if (bss->added_if_into_bridge) {
|
|
|
|
+ if (type == WPA_IF_AP_BSS && bss->added_if_into_bridge) {
|
|
|
|
if (linux_br_del_if(drv->ioctl_sock, bss->brname, bss->ifname)
|
|
|
|
< 0)
|
|
|
|
wpa_printf(MSG_INFO, "nl80211: Failed to remove "
|
|
|
|
"interface %s from bridge %s: %s",
|
|
|
|
bss->ifname, bss->brname, strerror(errno));
|
|
|
|
}
|
|
|
|
- if (bss->added_bridge) {
|
|
|
|
+ if (type == WPA_IF_AP_BSS && bss->added_bridge) {
|
|
|
|
if (linux_br_del(drv->ioctl_sock, bss->brname) < 0)
|
|
|
|
wpa_printf(MSG_INFO, "nl80211: Failed to remove "
|
|
|
|
"bridge %s: %s",
|