[Mono-bugs] [Bug 552664] New: XDocument.Load throw a NullReferenceException

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Wed Nov 4 17:15:07 EST 2009


http://bugzilla.novell.com/show_bug.cgi?id=552664


           Summary: XDocument.Load throw a NullReferenceException
    Classification: Mono
           Product: Mono: Class Libraries
           Version: 2.4.x
          Platform: x86
        OS/Version: Ubuntu
            Status: NEW
          Severity: Normal
          Priority: P5 - None
         Component: Sys.XML
        AssignedTo: atsushi at ximian.com
        ReportedBy: lnc19 at hotmail.com
         QAContact: mono-bugs at lists.ximian.com
          Found By: ---


User-Agent:       Mozilla/5.0 (X11; U; Linux i686; es-AR; rv:1.9.0.15)
Gecko/2009102815 Ubuntu/9.04 (jaunty) Firefox/3.0.15

Executing the following code throw an exception

FileStream fs = File.Open("/home/luciano/Encoding.xml", FileMode.Open);
XmlTextReader tr = new XmlTextReader (fs);
XDocument doc = XDocument.Load (tr);


Reproducible: Always

Steps to Reproduce:
1. Copy the code in some file
2. Compile
3. Run it
Actual Results:  
System.NullReferenceException: Object reference not set to an instance of an
object
  at System.Xml.Linq.XDocument.Load (System.Xml.XmlReader reader, LoadOptions
options) [0x00000] in
/home/luciano/mono242/mono-2.4.2.3/mcs/class/System.Xml.Linq/System.Xml.Linq/XDocument.cs:125 
  at System.Xml.Linq.XDocument.Load (System.Xml.XmlReader reader) [0x00000] in
/home/luciano/mono242/mono-2.4.2.3/mcs/class/System.Xml.Linq/System.Xml.Linq/XDocument.cs:120 


Expected Results:  
Load the Document

-- 
Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.


More information about the mono-bugs mailing list