One of the world's great coral reef regions protected fish from the ravages of climate change for the past 3 million years.