Fix XML validity.