[Mono-bugs] [Bug 503728] New: misused Type.GetInterfaceMap() causes runtime crash

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Wed May 13 23:22:51 EDT 2009


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


           Summary: misused Type.GetInterfaceMap() causes runtime crash
    Classification: Mono
           Product: Mono: Runtime
           Version: SVN
          Platform: i686
        OS/Version: Windows Vista
            Status: NEW
          Severity: Minor
          Priority: P5 - None
         Component: misc
        AssignedTo: mono-bugs at lists.ximian.com
        ReportedBy: atsushi at ximian.com
         QAContact: mono-bugs at lists.ximian.com
          Found By: ---


User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 6.0; en-US; rv:1.9.0.10)
Gecko/2009042316 Firefox/3.0.10 GTB5 (.NET CLR 3.5.30729)

Type.GetInterfaceMap(), when used for interface type (as the calling object),
should raise ArgumentException. Mono just causes runtime crash without throwing
AE.

using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Reflection;

public class Test
{
        public static void Main ()
        {
                typeof (IList<int>).GetInterfaceMap (typeof
(ICollection<int>));
        }
}


Reproducible: Always

Actual Results:  
$ mono ./iface.exe
Stacktrace:

  at (wrapper managed-to-native) System.Type.GetInterfaceMapData
(System.Type,System.Type,System.Reflection.MethodInfo[]&,System.Reflection.MethodInfo[]&)
<0x00004>
  at (wrapper managed-to-native) System.Type.GetInterfaceMapData
(System.Type,System.Type,System.Reflection.MethodInfo[]&,System.Reflection.MethodInfo[]&)
<0xffffffff>
  at System.Type.GetInterfaceMap (System.Type) <0x0005e>
  at TESt.Main () <0x00025>
  at (wrapper runtime-invoke) object.runtime_invoke_void
(object,intptr,intptr,intptr) <0xffffffff>


Expected Results:  
ArgumentException ("This" cannot be an interface type).

-- 
Configure bugmail: http://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