[Mono-bugs] [Bug 558741] New: [verifier] SIGSEGV in mono_type_get_basic_type_from_generic on a bad assembly

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Thu Nov 26 11:22:19 EST 2009


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

http://bugzilla.novell.com/show_bug.cgi?id=558741#c0


           Summary: [verifier] SIGSEGV in
                    mono_type_get_basic_type_from_generic on a bad
                    assembly
    Classification: Mono
           Product: Mono: Runtime
           Version: 2.6.x
          Platform: Other
        OS/Version: Other
            Status: NEW
          Severity: Normal
          Priority: P5 - None
         Component: misc
        AssignedTo: rkumpera at novell.com
        ReportedBy: spouliot at novell.com
         QAContact: mono-bugs at lists.ximian.com
          Found By: ---
           Blocker: ---


Created an attachment (id=329680)
 --> (http://bugzilla.novell.com/attachment.cgi?id=329680)
assembly to reproduce crash

pedump --verify all System.97986.dll

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0x7f970bbcc710 (LWP 16061)]
0x0000000000417c3c in mono_type_get_basic_type_from_generic (type=0x0) at
class.c:1365
1365        if (!type->byref && (type->type == MONO_TYPE_VAR || type->type ==
MONO_TYPE_MVAR))
(gdb) bt
#0  0x0000000000417c3c in mono_type_get_basic_type_from_generic (type=0x0) at
class.c:1365
#1  0x0000000000417eee in mono_class_layout_fields (class=0x8aaaa0) at
class.c:1445
#2  0x0000000000417bc7 in mono_class_setup_fields (class=0x8aaaa0) at
class.c:1310
#3  0x000000000041ee6b in mono_class_init (class=0x8aaaa0) at class.c:3966
#4  0x000000000040eb23 in verify_image_file (fname=0x7fff13bee2bb
"System.97986.dll") at pedump.c:475
#5  0x000000000040f376 in main (argc=4, argv=0x7fff13beda78) at pedump.c:692


The issue is that mono_class_enum_basetype can return NULL (SRE comment) so the
pattern (used 3 times in mono_class_layout_fields)

    ftype = mono_type_get_underlying_type (field->type);
    ftype = mono_type_get_basic_type_from_generic (ftype);

result in a SIGSEGV in mono_type_get_basic_type_from_generic.

-- 
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