Fix confusing error message on exit

* EXIT also seems to be emitted if the script exits normally
parent 35cb5d7c
......@@ -59,7 +59,8 @@ function clean_device() {
}
function clean_exit() {
echo "I: Cleaning up because the script exited before it could finish"
echo "I: Cleaning up"
unmount || true
clean || true
clean_device || true
}
......@@ -155,10 +155,3 @@ case "$INSTALL_MODE" in
fi
;;
esac
echo "I: Cleaning up host"
clean
echo "I: Cleaning up device"
clean_device
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment