Fixed BZ#978611 Some error messages were producing invalid XML content.