[Mono-bugs] [Bug 475852] New: monodocer NRE if exception tag contains bad attribute

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Fri Feb 13 16:07:28 EST 2009


https://bugzilla.novell.com/show_bug.cgi?id=475852


           Summary: monodocer NRE if exception tag contains bad attribute
    Classification: Mono
           Product: Mono: Doctools
           Version: 2.2.x
          Platform: x86
        OS/Version: Other
            Status: NEW
          Severity: Normal
          Priority: P5 - None
         Component: Console
        AssignedTo: mono-bugs at lists.ximian.com
        ReportedBy: bertrand.lorentz at gmail.com
         QAContact: mono-bugs at lists.ximian.com
          Found By: ---


User-Agent:       Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.0.5)
Gecko/2008121823 Gentoo Firefox/3.0.5 Ubiquity/0.1.5

If you're using the -importslashdoc option and the slashdoc XML contains an
<exception> tag with a bad attribute name (for example <exception
name="ArgumentOutOfRangeException"> instead of <exception
cref="ArgumentOutOfRangeException">), monodocer will crash with the following
exception :

monodocer: System.NullReferenceException: Object reference not set to an
instance of an object
  at Mono.Documentation.MDocUpdater.MakeDocNode
(Mono.Documentation.DocsNodeInfo info) [0x0070e] in
/var/tmp/portage/dev-lang/mono-2.2-r3/work/mono-2.2/mcs/tools/mdoc/Mono.Documentation/monodocer.cs:2059 
  at Mono.Documentation.MDocUpdater.UpdateMember
(Mono.Documentation.DocsNodeInfo info) [0x000cc] in
/var/tmp/portage/dev-lang/mono-2.2-r3/work/mono-2.2/mcs/tools/mdoc/Mono.Documentation/monodocer.cs:1737 
  at Mono.Documentation.MDocUpdater.MakeMember (System.Xml.XmlDocument doc,
Mono.Documentation.DocsNodeInfo info) [0x000ba] in
/var/tmp/portage/dev-lang/mono-2.2-r3/work/mono-2.2/mcs/tools/mdoc/Mono.Documentation/monodocer.cs:2549 
  at Mono.Documentation.MDocUpdater.DoUpdateType2 (System.String message,
System.Xml.XmlDocument basefile, System.Type type, System.String output,
Boolean insertSince, System.Xml.XmlReader ecmaDocsType) [0x00282] in
/var/tmp/portage/dev-lang/mono-2.2-r3/work/mono-2.2/mcs/tools/mdoc/Mono.Documentation/monodocer.cs:1033 
  at Mono.Documentation.MDocUpdater.StubType (System.Type type, System.String
output, System.Xml.XmlReader ecmaDocsType) [0x00029] in
/var/tmp/portage/dev-lang/mono-2.2-r3/work/mono-2.2/mcs/tools/mdoc/Mono.Documentation/monodocer.cs:1541 
  at Mono.Documentation.MDocUpdater.DoUpdateType (System.Type type,
System.String basepath, System.String dest, System.Xml.XmlReader ecmaDocsType)
[0x000fd] in
/var/tmp/portage/dev-lang/mono-2.2-r3/work/mono-2.2/mcs/tools/mdoc/Mono.Documentation/monodocer.cs:505 
  at Mono.Documentation.MDocUpdater.DoUpdateAssembly
(System.Reflection.Assembly assembly, System.Xml.XmlElement index_types,
System.String source, System.String dest, System.Collections.Hashtable
goodfiles) [0x00046] in
/var/tmp/portage/dev-lang/mono-2.2-r3/work/mono-2.2/mcs/tools/mdoc/Mono.Documentation/monodocer.cs:671 
  at Mono.Documentation.MDocUpdater.DoUpdateAssemblies (System.String source,
System.String dest) [0x000f9] in
/var/tmp/portage/dev-lang/mono-2.2-r3/work/mono-2.2/mcs/tools/mdoc/Mono.Documentation/monodocer.cs:649 
  at Mono.Documentation.MDocUpdater.Run (Mono.Documentation.MDocUpdaterOptions
opts) [0x0028b] in
/var/tmp/portage/dev-lang/mono-2.2-r3/work/mono-2.2/mcs/tools/mdoc/Mono.Documentation/monodocer.cs:299 


Reproducible: Always




I only tested this with mono 2.2, but looking at the code seems to indicate
that this would also happen with SVN trunk :

case "permission": {
    XmlElement a = (XmlElement) e.SelectSingleNode (child.Name + "[@cref='" +
child.Attributes ["cref"].Value + "']");

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


More information about the mono-bugs mailing list