aaa_error.sh: fix: don't erase tmpfile if we don't exit

This commit is contained in:
levasseur
2021-10-25 15:15:10 +02:00
parent 8dcd03ebe1
commit c7900a8911

View File

@@ -72,10 +72,10 @@ trap "error ${LINENO}; backtrace; err_exit" ERR
# Exit program in case of error unless keepgoing is set to true
function err_exit
{
if [[ -f $tmpfile ]]; then
rm -f $tmpfile
fi
if [[ $KEEPGOING != true ]]; then
if [[ -f $tmpfile ]]; then
rm -f $tmpfile
fi
exit 255
fi
}