I think it will take a lot longer than a million years for the Earth's core to freeze. There's a pretty big insulating layer around it!