X-Git-Url: https://git.archive.openwrt.org/?a=blobdiff_plain;f=package%2Fmac80211%2Ffiles%2Flib%2Fwifi%2Fmac80211.sh;h=f1d89f87a01088ffa7eef5848c649f8bc2b8c5f3;hb=028570018dafdcbb7e103c95d88d7436689b3c19;hp=b20785cf672316c73947019cbdec223086c39945;hpb=9577fc90b0eabeaa998f3bfb6c5360549278e7cc;p=openwrt.git diff --git a/package/mac80211/files/lib/wifi/mac80211.sh b/package/mac80211/files/lib/wifi/mac80211.sh index b20785cf67..f1d89f87a0 100644 --- a/package/mac80211/files/lib/wifi/mac80211.sh +++ b/package/mac80211/files/lib/wifi/mac80211.sh @@ -6,6 +6,9 @@ mac80211_hostapd_setup_base() { local ifname="$2" cfgfile="/var/run/hostapd-$phy.conf" + macfile="/var/run/hostapd-$phy.maclist" + [ -e "$macfile" ] && rm -f "$macfile" + config_get device "$vif" device config_get country "$device" country config_get hwmode "$device" hwmode @@ -30,7 +33,25 @@ mac80211_hostapd_setup_base() { [ -n "$ht_capab" ] && append base_cfg "ht_capab=$ht_capab" "$N" } } - cat > "$cfgfile" <> $macfile + done + } + cat >> "$cfgfile" </dev/null >/dev/null; then