diff options
-rwxr-xr-x | bin/impressive-display | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/bin/impressive-display b/bin/impressive-display index 2ddbc4f..bc0bac4 100755 --- a/bin/impressive-display +++ b/bin/impressive-display @@ -331,8 +331,13 @@ function download_pdffile { if [ -f "$workdir/secrets/$THIS_HOSTNAME.secret" ]; then NETRCFILE=" --netrc-file $workdir/secrets/${THIS_HOSTNAME}.secret" fi - if ! curl $NETRCFILE "$PDF_URI" 1> "$DOWNLOADED_FILE"; then - $OUTPUT "The curl tool failed in retrieving PDF file." + + if [ "x$LOG_TO_SYSLOG" = "xyes" ]; then + if ! curl $NETRCFILE "$PDF_URI" 1> "$DOWNLOADED_FILE" 2>/dev/null; then + $OUTPUT "The curl tool failed in retrieving PDF file. Run this tool interactively to debug problems." + fi + else + curl $NETRCFILE "$PDF_URI" 1> "$DOWNLOADED_FILE" fi # is the PDF file gzipped? |