2011-01-25 02:54:20 +08:00
|
|
|
--- a/src/drivers/driver_nl80211.c
|
|
|
|
+++ b/src/drivers/driver_nl80211.c
|
2013-08-09 00:04:19 +08:00
|
|
|
@@ -8145,12 +8145,7 @@ static int wpa_driver_nl80211_set_mode(s
|
2013-07-01 04:27:38 +08:00
|
|
|
/* Try to set the mode again while the interface is
|
|
|
|
* down */
|
2011-01-25 02:54:20 +08:00
|
|
|
ret = nl80211_set_mode(drv, drv->ifindex, nlmode);
|
2013-07-01 04:27:38 +08:00
|
|
|
- if (ret == -EACCES)
|
|
|
|
- break;
|
|
|
|
- res = i802_set_iface_flags(bss, 1);
|
|
|
|
- if (res && !ret)
|
|
|
|
- ret = -1;
|
|
|
|
- else if (ret != -EBUSY)
|
|
|
|
+ if (ret != -EBUSY)
|
2011-01-25 02:54:20 +08:00
|
|
|
break;
|
2013-07-01 04:27:38 +08:00
|
|
|
} else
|
|
|
|
wpa_printf(MSG_DEBUG, "nl80211: Failed to set "
|
2013-08-09 00:04:19 +08:00
|
|
|
@@ -8163,6 +8158,8 @@ static int wpa_driver_nl80211_set_mode(s
|
2011-01-25 02:54:20 +08:00
|
|
|
"interface is down");
|
|
|
|
drv->nlmode = nlmode;
|
2011-11-04 09:05:26 +08:00
|
|
|
drv->ignore_if_down_event = 1;
|
2013-07-01 04:27:38 +08:00
|
|
|
+ if (i802_set_iface_flags(bss, 1))
|
|
|
|
+ ret = -1;
|
2011-01-25 02:54:20 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
done:
|