err_exit: better check file existance than variable being set before cleaning up temp file
This commit is contained in:
@@ -72,7 +72,7 @@ trap "error ${LINENO}; backtrace; err_exit" ERR
|
||||
# Exit program in case of error unless keepgoing is set to true
|
||||
function err_exit
|
||||
{
|
||||
if [[ -n $tmpfile ]]; then
|
||||
if [[ -f $tmpfile ]]; then
|
||||
rm -f $tmpfile
|
||||
fi
|
||||
if [[ $KEEPGOING != true ]]; then
|
||||
|
||||
Reference in New Issue
Block a user