Whitespaces in attributes are normalized by default to be converted to spaces. It is much safer to have text with new lines in elements instead of attributes.
If it is out of your control - setting XmlTextReader.Normalization to false
should prevent default behavior.
Partial sample from the article below:
// Create the XML fragment to be parsed.
string xmlFrag =
@"<item attr1=' test A B C
1 2 3'/>
<item attr2=''/>";
XmlTextReader reader = new XmlTextReader(xmlFrag, XmlNodeType.Element, context);
// Show attribute value normalization.
reader.Read();
reader.Normalization = false;
Console.WriteLine("Attribute value:{0}", reader.GetAttribute("attr1"));
reader.Normalization = true;
Console.WriteLine("Attribute value:{0}", reader.GetAttribute("attr1"));