From 3b4faf7fdfe450c5fe044c5f1740d83fc36b2ce3 Mon Sep 17 00:00:00 2001 From: Patrick McDermott Date: Thu, 25 Apr 2019 19:47:52 -0400 Subject: src/feed.sh: Delimit command operands --- (limited to 'src') diff --git a/src/feed.sh b/src/feed.sh index 9ca101a..d45e977 100644 --- a/src/feed.sh +++ b/src/feed.sh @@ -49,11 +49,11 @@ feed_download() url="${base_url}/Packages" fi - if ! ${WGET} -q -O "${list_file}.tmp" "${url}"; then + if ! ${WGET} -q -O "${list_file}.tmp" -- "${url}"; then return 1 fi if ! ${gunzip} <"${list_file}.tmp" >"${list_file}"; then - rm -f "${list_file}.tmp" + rm -f -- "${list_file}.tmp" return 1 fi rm -f "${list_file}.tmp" @@ -81,11 +81,12 @@ feed_download_cert() url="${base_url}/Packages" fi - if ! ${WGET} -q -O "${list_file}.tmp" "${url}"; then + if ! ${WGET} -q -O "${list_file}.tmp" -- "${url}"; then return 1 fi - if ! ${WGET} -q -O "${list_file}.sig" "${base_url}/Packages.sig"; then - rm -f "${list_file}.tmp" + if ! ${WGET} -q -O "${list_file}.sig" -- "${base_url}/Packages.sig" + then + rm -f -- "${list_file}.tmp" return 1 fi @@ -103,10 +104,10 @@ feed_download_cert() if ! ROOT="${root}" TMPDIR="${root}" USIGN="${usign}" \ WGET="${WGET}" GUNZIP="${GUNZIP}" "${opkg_cert}" \ verify "${list_file}.sig" "${list_file}.tmp"; then - rm -f "${list_file}.tmp" "${list_file}.sig" + rm -f -- "${list_file}.tmp" "${list_file}.sig" return 1 fi - mv "${list_file}.tmp" "${list_file}" + mv -- "${list_file}.tmp" "${list_file}" return 0 } -- cgit v0.9.1