From: Benjamin Dos Santos Date: Sun, 6 Dec 2015 00:33:40 +0000 (+0100) Subject: style: double quote to prevent globbing and word splitting X-Git-Tag: v0.1.0~210 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c4be4c695a09f6e84c23dd49ac15dd31ebcb7f90;p=thirdparty%2Fdehydrated.git style: double quote to prevent globbing and word splitting https://github.com/koalaman/shellcheck/wiki/Sc2086 --- diff --git a/letsencrypt.sh b/letsencrypt.sh index 0c1d544..ec5467f 100755 --- a/letsencrypt.sh +++ b/letsencrypt.sh @@ -48,11 +48,11 @@ hex2bin() { _request() { temperr="$(mktemp)" if [[ "${1}" = "head" ]]; then - curl -sSf -I "${2}" 2>${temperr} + curl -sSf -I "${2}" 2> "${temperr}" elif [[ "${1}" = "get" ]]; then - curl -sSf "${2}" 2>${temperr} + curl -sSf "${2}" 2> "${temperr}" elif [[ "${1}" = "post" ]]; then - curl -sSf "${2}" -d "${3}" 2>${temperr} + curl -sSf "${2}" -d "${3}" 2> "${temperr}" fi if [[ ! -z "$(<${temperr})" ]]; then @@ -181,6 +181,6 @@ if [[ "${register}" = "1" ]]; then fi # Generate certificates for all domains found in domain.txt (TODO: check if certificate already exists and is about to expire) -