Make written value in WriteName const.

Make the vector<CNameIndex> value passed to WriteName const, as it
should be (since it won't be changed).