exit with code 1 in an error case