diff options
author | Alex Thibodeau <alexthibodeau@unity3d.com> | 2020-02-02 19:29:57 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-02-02 19:29:57 +0300 |
commit | 050340ef1a16ee94835d3495240cf1fe5297ba5f (patch) | |
tree | 6d8ab8145b675d5aa66bc607dcaddf10d9cf3283 | |
parent | 4bed68d0731ebe13393e7404d5975079c3fdcd87 (diff) |
Adjust mono_class_init_internal to no longer bypass cleanup when a failure is detected. (#18649)
This fixes: https://issuetracker.unity3d.com/issues/unity-physics-collisions-do-not-work-and-errors-are-thrown-when-entering-play-mode
-rw-r--r-- | mono/metadata/class-init.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/mono/metadata/class-init.c b/mono/metadata/class-init.c index 3529a2824f3..3a8cd75b250 100644 --- a/mono/metadata/class-init.c +++ b/mono/metadata/class-init.c @@ -4548,9 +4548,8 @@ mono_class_init_internal (MonoClass *klass) locked = TRUE; if (klass->inited || mono_class_has_failure (klass)) { - mono_loader_unlock (); /* Somebody might have gotten in before us */ - return !mono_class_has_failure (klass); + goto leave; } UnlockedIncrement (&mono_stats.initialized_class_count); |