Merge pull request #2454 from tastywheattasteslikechicken/FixVtableAbort
[mono.git] / mono / mini / mini-runtime.c
index cb8b970b827c2b89828f3aa6d239e0b735bad9c5..136239a1211c7c217c32221e20bcd5faccc72aa4 100644 (file)
@@ -2007,7 +2007,13 @@ mono_jit_compile_method_with_opt (MonoMethod *method, guint32 opt, MonoError *er
                        MonoVTable *vtable;
 
                        mono_jit_stats.methods_lookups++;
-                       vtable = mono_class_vtable (domain, method->klass);
+
+                       vtable = mono_class_vtable_full (domain, method->klass, ex == NULL);
+                       if (ex && method->klass->exception_type) {
+                               *ex = mono_class_get_exception_for_failure (method->klass);
+                               return NULL;
+                       }
+
                        g_assert (vtable);
                        if (!mono_runtime_class_init_full (vtable, error))
                                return NULL;
@@ -3310,6 +3316,8 @@ mini_parse_debug_option (const char *option)
                mono_align_small_structs = TRUE;
        else if (!strcmp (option, "native-debugger-break"))
                debug_options.native_debugger_break = TRUE;
+       else if (!strcmp (option, "disable_omit_fp"))
+               debug_options.disable_omit_fp = TRUE;
        else
                return FALSE;