exit reinstall.sh with error code

if something went wrong