Yes, catch an exception should be good, it will protect it to be crashed.