[commits] [openwrt-feed-devel] master: batman-adv: Don't try to set unconfigured ap_isolation for vlan (aa494d3)

postmaster at open-mesh.org postmaster at open-mesh.org
Thu Aug 1 16:55:17 CEST 2019


Repository : ssh://git@open-mesh.org/openwrt-feed-devel

On branch  : master

>---------------------------------------------------------------

commit aa494d39d92ee870cdfa721cf0979843635f64e0
Author: Sven Eckelmann <sven at narfation.org>
Date:   Sun Jun 16 09:27:08 2019 +0200

    batman-adv: Don't try to set unconfigured ap_isolation for vlan
    
    The ap_isolation setting only supports boolean values. So setting an empty
    string as ap_isolation is not supported by batctl.
    
    Fixes: 26284d39c413 ("batman-adv-devel: enable batadv_vlan protocol")
    Signed-off-by: Sven Eckelmann <sven at narfation.org>


>---------------------------------------------------------------

aa494d39d92ee870cdfa721cf0979843635f64e0
 batman-adv-devel/files/lib/netifd/proto/batadv_vlan.sh | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/batman-adv-devel/files/lib/netifd/proto/batadv_vlan.sh b/batman-adv-devel/files/lib/netifd/proto/batadv_vlan.sh
index d6d00ad..b4835f6 100755
--- a/batman-adv-devel/files/lib/netifd/proto/batadv_vlan.sh
+++ b/batman-adv-devel/files/lib/netifd/proto/batadv_vlan.sh
@@ -5,7 +5,7 @@
 init_proto "$@"
 
 proto_batadv_vlan_init_config() {
-	proto_config_add_string "ap_isolation"
+	proto_config_add_boolean 'ap_isolation:bool'
 }
 
 proto_batadv_vlan_setup() {
@@ -17,7 +17,7 @@ proto_batadv_vlan_setup() {
 
 	json_get_vars ap_isolation
 
-	batctl -m "$iface" ap_isolation "$ap_isolation"
+	[ -n "$ap_isolation" ] && batctl -m "$iface" ap_isolation "$ap_isolation"
 	proto_init_update "$iface" 1
 	proto_send_update "$config"
 }



More information about the commits mailing list