1 --- a/hostapd/driver_madwifi.c
2 +++ b/hostapd/driver_madwifi.c
3 @@ -298,6 +298,7 @@ madwifi_set_iface_flags(void *priv, int
5 struct madwifi_driver_data *drv = priv;
9 wpa_printf(MSG_DEBUG, "%s: dev_up=%d", __func__, dev_up);
11 @@ -312,10 +313,14 @@ madwifi_set_iface_flags(void *priv, int
15 + flags = ifr.ifr_flags;
17 - ifr.ifr_flags |= IFF_UP;
20 - ifr.ifr_flags &= ~IFF_UP;
23 + if (flags == ifr.ifr_flags)
26 if (ioctl(drv->ioctl_sock, SIOCSIFFLAGS, &ifr) != 0) {
27 perror("ioctl[SIOCSIFFLAGS]");