Minor error handling optimization

Get faster out of a block in case of an error