commit cc12bddb09e5476af551fc0599156fe1ca33cff0
parent 0d428ceed7571aabe681c783d513898a4c62b735
Author: hhvn <dev@hhvn.uk>
Date: Tue, 3 Aug 2021 18:00:06 +0100
.s/b/netdownload: skip empty lines
Diffstat:
1 file changed, 1 insertion(+), 0 deletions(-)
diff --git a/.scripts/bin/netdownload b/.scripts/bin/netdownload
@@ -45,6 +45,7 @@ case "$1" in
uri=$(printf '%s\n' "$line" | awk -F"\t" '{print $2}')
# let $3 be comment, therefore no need to handle
+ [ -z "$line" ] && continue
[ -z "$dir" ] || [ -z "$uri" ] &&
printf "ERROR: Erroneous syntax on line %d\n" "$linec" &&
continue