mono_domain_unlock (domain);
mono_loader_unlock ();
- /* Initialization is now complete, we can throw if the InheritanceDemand aren't satisfied */
- if (mono_security_enabled () && (class->exception_type == MONO_EXCEPTION_SECURITY_INHERITANCEDEMAND) && raise_on_error)
- mono_raise_exception (mono_class_get_exception_for_failure (class));
-
/* make sure the parent is initialized */
/*FIXME shouldn't this fail the current type?*/
if (class->parent)
if (exc == (MonoObject*)mono_object_domain (exc)->out_of_memory_ex) {
message = g_strdup ("OutOfMemoryException");
free_message = TRUE;
+ } else if (exc == (MonoObject*)mono_object_domain (exc)->stack_overflow_ex) {
+ message = g_strdup ("StackOverflowException"); //if we OVF, we can't expect to have stack space to JIT Exception::ToString.
+ free_message = TRUE;
} else {
if (((MonoException*)exc)->native_trace_ips) {
g_assert (this);
g_assert (addr);
+ g_assert (mono_class_has_parent (mono_object_class (this), mono_defaults.multicastdelegate_class));
+
if (method)
delegate->method = method;