summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTimo Weingärtner <timo@tiwe.de>2021-07-19 13:36:58 +0200
committerTimo Weingärtner <timo@tiwe.de>2021-07-19 13:36:58 +0200
commitf855dc5ac98432ef4b126446c50a9737d98f0fb8 (patch)
treec1ce6233c2fd7de1792a3ce2277f50fba570ee0a
parent53614d19826293d753aad599f2b2900d8d6303ed (diff)
downloadopenssh-known-hosts-f855dc5ac98432ef4b126446c50a9737d98f0fb8.tar.gz
always use read with -r
-rwxr-xr-xupdate-openssh-known-hosts6
1 files changed, 3 insertions, 3 deletions
diff --git a/update-openssh-known-hosts b/update-openssh-known-hosts
index 325a997..9eee3ec 100755
--- a/update-openssh-known-hosts
+++ b/update-openssh-known-hosts
@@ -99,7 +99,7 @@ cd "${CACHEDIR}"
find -mindepth 2 -maxdepth 2 -type f -name new -delete
-run-parts --list "${CONFDIR}/sources/" | while read sourcefile; do
+run-parts --list "${CONFDIR}/sources/" | while read -r sourcefile; do
source=${sourcefile##*/}
mkdir -p "${source}"
download_source "${source}" "${sourcefile}"
@@ -115,8 +115,8 @@ run-parts --list "${CONFDIR}/sources/" | while read sourcefile; do
unset filter[$i]
fi
done
- while read hostlist rest; do
- IFS=, read -a hostarray <<<"$hostlist"
+ while read -r hostlist rest; do
+ IFS=, read -ra hostarray <<<"$hostlist"
new_hostlist=''
for host in "${hostarray[@]}"; do
for rule in "${filter[@]}"; do