From 83714c767f16c5d4705602ecaea5a75785483854 Mon Sep 17 00:00:00 2001 From: Calin Crisan Date: Tue, 1 Oct 2019 23:29:25 +0300 Subject: [PATCH] fwupdate: show curl log upon download error --- board/common/overlay/sbin/fwupdate | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/board/common/overlay/sbin/fwupdate b/board/common/overlay/sbin/fwupdate index 78dd4c58ca..2529b54fd6 100755 --- a/board/common/overlay/sbin/fwupdate +++ b/board/common/overlay/sbin/fwupdate @@ -291,12 +291,16 @@ function do_download() { curl ${curl_opts} -o ${outfile} "${url}" &> ${CURL_LOG_FILE} & pid=$! echo ${pid} > ${CURL_PID_FILE} + + set +e # don't exit on error just yet wait ${pid} if [[ "$?" != 0 ]]; then cat ${CURL_LOG_FILE} exit 1 fi + + set -e } function download_status() {