Exit process when exception happen and remove input value first