我有以下代码来加载 XML
var ms = new GetXmlMemoryStreamFromSomewhere();
ms.Flush();
ms.Position = 0;
// Build the XmlDocument from the MemorySteam of (usually UTF-8) encoded bytes
xmlDocument.Load(ms);
我的流的字节大小为 27011。上面代码中的最后一行失败了System.Net.WebException Operation timed out
Watch
forms.Position
表示它4096
没有读取超过 4096 个字节。
对此的任何指示将不胜感激。