tinc: use 'uci_get_state' instead of 'uci -P /var/state get'
authorEtienne Champetier <champetier.etienne@gmail.com>
Thu, 12 Aug 2021 20:41:05 +0000 (16:41 -0400)
committerRosen Penev <rosenp@gmail.com>
Wed, 1 Sep 2021 21:12:26 +0000 (14:12 -0700)
Signed-off-by: Etienne Champetier <champetier.etienne@gmail.com>
net/tinc/Makefile
net/tinc/files/tinc.init

index 945693925ff30531e01460f433f2303227cbcdf1..54936d19afeed675ba6a6b0c5045c3c9d5bfbeaf 100644 (file)
@@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
 
 PKG_NAME:=tinc
 PKG_VERSION:=1.1-git
-PKG_RELEASE:=2
+PKG_RELEASE:=3
 
 PKG_SOURCE_PROTO:=git
 PKG_SOURCE_URL:=http://tinc-vpn.org/git/tinc
index af2c3bcac0d1d0d4dc352fda076cf19d82a45052..ba2134fe0f680807bc2f20f7f05ec876351dbb3e 100644 (file)
@@ -61,7 +61,7 @@ append_conf_params() {
                for v in $v; do
                        # Look up OpenWRT interface names
                        [ "$p" = "BindToInterface" ] && {
-                               local ifname=$(uci -P /var/state get network.$v.ifname 2>&-)
+                               local ifname=$(uci_get_state network "$v" ifname "")
                                [ -n "$ifname" ] && v="$ifname"
                        }