Allowing file redirection within CESM.

CESM expects each component to write to a specific file, and it defines
the unit number that this file uses.

This commit fixes issues related to this.