Rescues / retries a block, up to a number of times.