aboutsummaryrefslogtreecommitdiffstats
path: root/package/network/services/hostapd/files/netifd.sh
diff options
context:
space:
mode:
Diffstat (limited to 'package/network/services/hostapd/files/netifd.sh')
-rw-r--r--package/network/services/hostapd/files/netifd.sh7
1 files changed, 5 insertions, 2 deletions
diff --git a/package/network/services/hostapd/files/netifd.sh b/package/network/services/hostapd/files/netifd.sh
index 9b40a23451..1c91bbf3c8 100644
--- a/package/network/services/hostapd/files/netifd.sh
+++ b/package/network/services/hostapd/files/netifd.sh
@@ -1,3 +1,5 @@
+. /lib/functions/network.sh
+
wpa_supplicant_add_rate() {
local var="$1"
local val="$(($2 / 1000))"
@@ -351,8 +353,9 @@ hostapd_set_bss_options() {
append bss_conf "ssid=$ssid" "$N"
[ -n "$network_bridge" ] && append bss_conf "bridge=$network_bridge" "$N"
[ -n "$iapp_interface" ] && {
- iapp_interface="$(uci_get_state network "$iapp_interface" ifname "$iapp_interface")"
- [ -n "$iapp_interface" ] && append bss_conf "iapp_interface=$iapp_interface" "$N"
+ local ifname
+ network_get_device ifname "$iapp_interface" || ifname = "$iapp_interface"
+ append bss_conf "iapp_interface=$ifname" "$N"
}
if [ "$wpa" -ge "1" ]; then