diff options
| author | Jonathan Bauer | 2016-01-08 14:28:46 +0100 |
|---|---|---|
| committer | Jonathan Bauer | 2016-01-08 14:28:46 +0100 |
| commit | 7106ee223592a0591e267daa7f71162e4ad658b0 (patch) | |
| tree | 490d793b56807918cbd6197086b5251d08a18145 /remote/modules/printergui/data/opt | |
| parent | [exam] renamed safe-mode service to 'exam.service' and removed unneeded code (diff) | |
| parent | [run-virt] openslx.exe: Hide console, re-set logoff caption periodically (diff) | |
| download | tm-scripts-7106ee223592a0591e267daa7f71162e4ad658b0.tar.gz tm-scripts-7106ee223592a0591e267daa7f71162e4ad658b0.tar.xz tm-scripts-7106ee223592a0591e267daa7f71162e4ad658b0.zip | |
Merge branch 'master' of git.openslx.org:openslx-ng/tm-scripts
Diffstat (limited to 'remote/modules/printergui/data/opt')
| -rwxr-xr-x | remote/modules/printergui/data/opt/openslx/scripts/run-virt_print | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/remote/modules/printergui/data/opt/openslx/scripts/run-virt_print b/remote/modules/printergui/data/opt/openslx/scripts/run-virt_print index dfbcdfde..ba352778 100755 --- a/remote/modules/printergui/data/opt/openslx/scripts/run-virt_print +++ b/remote/modules/printergui/data/opt/openslx/scripts/run-virt_print @@ -45,8 +45,10 @@ if which gs 2>/dev/null; then RET=$? if [ $RET -ne 0 ]; then errlog "printergui-validate" "Error: Ghostscript choked on input file" "$ERRLOG" + rm -f -- "$ERRLOG" exit 1 fi + rm -f -- "$ERRLOG" else errlog "printergui-nogs" "Warning: Cannot validate file prior to printing: gs binary not found" fi @@ -57,5 +59,9 @@ RET=$? if [ $RET -ne 0 -a $RET -ne 143 ]; then # SIGTERM results in 143, is sent by printpwgui errlog "printergui-exec" "Error: printergui execution failed with exit code $RET" fi + +sleep 1 +rm -f -- "$FILE" + exit $RET |
