aboutsummaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authorTom Ryder <tom@sanctum.geek.nz>2016-06-18 13:51:49 +1200
committerTom Ryder <tom@sanctum.geek.nz>2016-06-18 13:51:49 +1200
commit38f85e9ffb4d6b585298e86a3145f8ba6d0a6518 (patch)
treea93cc84112f323cb1202efd072357ef7ba8395f3 /bin
parentRemove two lines no longer used (diff)
downloaddotfiles-38f85e9ffb4d6b585298e86a3145f8ba6d0a6518.tar.gz
dotfiles-38f85e9ffb4d6b585298e86a3145f8ba6d0a6518.zip
Add option terminators to curl(1) calls
Diffstat (limited to 'bin')
-rwxr-xr-xbin/urlcheck4
1 files changed, 2 insertions, 2 deletions
diff --git a/bin/urlcheck b/bin/urlcheck
index 4446f94e..21f41c7e 100755
--- a/bin/urlcheck
+++ b/bin/urlcheck
@@ -10,7 +10,7 @@ cleanup() {
trap cleanup EXIT
while read -r url ; do
[[ $url == 'http'* ]] || continue
- if ! curl -fHLsS -D "$head" -m "$tm" -o "$body" "$url" ; then
+ if ! curl -fHLsS -D "$head" -m "$tm" -o "$body" -- "$url" ; then
printf '%s: %s raises error\n' \
"$self" "$url" >&2
continue
@@ -23,7 +23,7 @@ while read -r url ; do
done < "$head"
[[ $url == 'http:'* ]] || continue
securl=${url/http:/https:}
- if curl -fLsS -m "$tm" -o /dev/null -- "$securl" 2>/dev/null ; then
+ if curl -fLsS -D "$head" -m "$tm" -o "$body" -- "$securl" 2>/dev/null ; then
printf '%s: %s has a working secure version at %s\n' \
"$self" "$url" "$securl" >&2
((ex++))