From 141342ea20c8e070f9f2633f86167168e498437b Mon Sep 17 00:00:00 2001 From: Mikhail Novosyolov Date: Wed, 1 Sep 2021 15:14:31 +0300 Subject: [PATCH] fix correct exit --- cups-backend-copy-raw.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cups-backend-copy-raw.sh b/cups-backend-copy-raw.sh index d7618d5..c2f93c1 100755 --- a/cups-backend-copy-raw.sh +++ b/cups-backend-copy-raw.sh @@ -42,7 +42,7 @@ CUPS_BACKEND_RETRY_CURRENT=7 # Job failed, retry this job immediately # We use 'set -e', script may fail somewhere, # make CUPS restart the job later if the error was unexpected _trap_exit(){ - if [ $? != "$CUPS_BACKEND_FAILED" ]; then + if [ $? != "$CUPS_BACKEND_OK" ] && [ $? != "$CUPS_BACKEND_FAILED" ]; then exit "$CUPS_BACKEND_RETRY" fi }