openwrtv3/package/network/services/hostapd/patches/510-bring_down_interface.patch
Felix Fietkau 60b040bbaf hostapd: update to latest git version
Signed-off-by: Felix Fietkau <nbd@openwrt.org>

SVN-Revision: 37110
2013-06-30 20:27:38 +00:00

25 lines
712 B
Diff

--- a/src/drivers/driver_nl80211.c
+++ b/src/drivers/driver_nl80211.c
@@ -8102,12 +8102,7 @@ static int wpa_driver_nl80211_set_mode(s
/* Try to set the mode again while the interface is
* down */
ret = nl80211_set_mode(drv, drv->ifindex, nlmode);
- if (ret == -EACCES)
- break;
- res = i802_set_iface_flags(bss, 1);
- if (res && !ret)
- ret = -1;
- else if (ret != -EBUSY)
+ if (ret != -EBUSY)
break;
} else
wpa_printf(MSG_DEBUG, "nl80211: Failed to set "
@@ -8120,6 +8115,8 @@ static int wpa_driver_nl80211_set_mode(s
"interface is down");
drv->nlmode = nlmode;
drv->ignore_if_down_event = 1;
+ if (i802_set_iface_flags(bss, 1))
+ ret = -1;
}
done: