[OpenWrt-Devel] [PATCH v2] ipq806x: Replace backticks by $(...)

Adrian Schmutzler freifunk at adrianschmutzler.de
Wed Jul 24 18:43:00 EDT 2019


This replaces deprecated backticks by more versatile $(...) syntax.

Signed-off-by: Adrian Schmutzler <freifunk at adrianschmutzler.de>
---
 .../base-files/etc/hotplug.d/ieee80211/10_fix_wifi_mac      | 6 +++---
 target/linux/ipq806x/base-files/lib/upgrade/linksys.sh      | 2 +-
 2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/target/linux/ipq806x/base-files/etc/hotplug.d/ieee80211/10_fix_wifi_mac b/target/linux/ipq806x/base-files/etc/hotplug.d/ieee80211/10_fix_wifi_mac
index 4b476e56ae..f0256fd259 100644
--- a/target/linux/ipq806x/base-files/etc/hotplug.d/ieee80211/10_fix_wifi_mac
+++ b/target/linux/ipq806x/base-files/etc/hotplug.d/ieee80211/10_fix_wifi_mac
@@ -13,13 +13,13 @@ OPATH=${DEVPATH##/devices/platform/}
 OPATH=${OPATH%%/ieee*}
 
 # 10 radios is enough for anyone!
-for i in `seq 0 9`;
+for i in $(seq 0 9);
   do
-  BUS=`uci get wireless. at wifi-device[$i].path`
+  BUS=$(uci get wireless. at wifi-device[$i].path)
   if [ "$BUS " == "$OPATH " ]
       then
       PHYNAME=${DEVPATH##*ieee80211/}
-      NPHYNAME=`uci get wireless. at wifi-device[$i].phyname`
+      NPHYNAME=$(uci get wireless. at wifi-device[$i].phyname)
       if [ "$NPHYNAME " != " " ]
           then
           if [ "$PHYNAME " != "$NPHYNAME " ]
diff --git a/target/linux/ipq806x/base-files/lib/upgrade/linksys.sh b/target/linux/ipq806x/base-files/lib/upgrade/linksys.sh
index 2aa6e0f08c..a957bf1149 100644
--- a/target/linux/ipq806x/base-files/lib/upgrade/linksys.sh
+++ b/target/linux/ipq806x/base-files/lib/upgrade/linksys.sh
@@ -21,7 +21,7 @@ linksys_get_target_firmware() {
 			"${cur_boot_part}" "${mtd_ubi0}"
 	fi
 
-	cur_boot_part=`/usr/sbin/fw_printenv -n boot_part`
+	cur_boot_part=$(/usr/sbin/fw_printenv -n boot_part)
 
 	case $cur_boot_part in
 	1)
-- 
2.20.1


_______________________________________________
openwrt-devel mailing list
openwrt-devel at lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel



More information about the openwrt-devel mailing list