aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKerin Millar <kfm@plushkava.net>2023-01-17 09:25:58 +0000
committerSam James <sam@gentoo.org>2023-01-17 15:06:28 +0000
commit9f752fd223ce8a2539874631008d9eda83aa5ba0 (patch)
tree3e9c0eaa074c652272602f116ab7afda7c8d9f51
parentnet/veth.sh: Eliminate the bashism that is the == test operator (diff)
downloadnetifrc-9f752fd223ce8a2539874631008d9eda83aa5ba0.tar.gz
netifrc-9f752fd223ce8a2539874631008d9eda83aa5ba0.tar.bz2
netifrc-9f752fd223ce8a2539874631008d9eda83aa5ba0.zip
net/wpa_supplicant.sh: Properly expand the number of positional parameters
${#*} is undefined behaviour. Just write it as $#. Signed-off-by: Kerin Millar <kfm@plushkava.net> Signed-off-by: Sam James <sam@gentoo.org>
-rw-r--r--net/wpa_supplicant.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/wpa_supplicant.sh b/net/wpa_supplicant.sh
index 3f8e1b1..9f024c0 100644
--- a/net/wpa_supplicant.sh
+++ b/net/wpa_supplicant.sh
@@ -57,7 +57,7 @@ wpa_supplicant_pre_start()
[ -z "${cliopts}" ] && cliopts=${wpa_cli}
set -- $opts
local opt_D
- while [ ${#*} -gt 0 ]; do
+ while [ "$#" -gt 0 ]; do
local opt=$1 ; shift
case "$opt" in
-D) opt_D=${1} ; shift ;;