diff --git a/misc/core.func b/misc/core.func index e0bc6debc..ea4bd828d 100644 --- a/misc/core.func +++ b/misc/core.func @@ -115,9 +115,9 @@ silent() { run_curl() { if [ "$VERB" = "no" ]; then - curl "$@" 2>/tmp/curl_error.log >/dev/null + curl "$@" >/dev/null 2>>/tmp/curl_error.log else - curl "$@" + curl "$@" 2>>/tmp/curl_error.log fi } @@ -137,7 +137,7 @@ curl_handler() { if [[ -z "$url" ]]; then msg_error "no valid url or option entered for curl_handler" - return 1 + exit 1 fi $STD msg_info "Fetching: $url" @@ -166,7 +166,7 @@ curl_handler() { rm -f /tmp/curl_error.log fi __curl_err_handler "$exit_code" "$url" "$curl_stderr" - return 1 + exit 1 # hard exit if exit_code is not 0 fi $STD printf "\r\033[K${INFO}${YW}Retry $attempt/$max_retries in ${delay}s...${CL}" >&2