This should have gone in with the implementation of BaseDnsWriter. ------------- Created by MOE: https://github.com/google/moe MOE_MIGRATED_REVID=232009971