Author: miguel
Date: 2007-04-29 00:58:06 -0400 (Sun, 29 Apr 2007)
New Revision: 76440
Modified:
branches/mono-1-2-4/mono/mono/metadata/ChangeLog
branches/mono-1-2-4/mono/mono/metadata/threads.c
Log:
backport 2007-04-28 Zoltan Varga <[EMAIL PROTECTED]>
* threads.c (build_wait_tids): Do not call mono_monitor_enter () here
since the
caller holds threads_lock, leading to deadlocks. Fixes #81476.
Modified: branches/mono-1-2-4/mono/mono/metadata/ChangeLog
===================================================================
--- branches/mono-1-2-4/mono/mono/metadata/ChangeLog 2007-04-29 04:36:33 UTC
(rev 76439)
+++ branches/mono-1-2-4/mono/mono/metadata/ChangeLog 2007-04-29 04:58:06 UTC
(rev 76440)
@@ -1,3 +1,8 @@
+2007-04-28 Zoltan Varga <[EMAIL PROTECTED]>
+
+ * threads.c (build_wait_tids): Do not call mono_monitor_enter () here
since the
+ caller holds threads_lock, leading to deadlocks. Fixes #81476.
+
2007-04-23 Jonathan Chambers <[EMAIL PROTECTED]>
* marshal.c: Fix calling convention for CCW on non-windows
Modified: branches/mono-1-2-4/mono/mono/metadata/threads.c
===================================================================
--- branches/mono-1-2-4/mono/mono/metadata/threads.c 2007-04-29 04:36:33 UTC
(rev 76439)
+++ branches/mono-1-2-4/mono/mono/metadata/threads.c 2007-04-29 04:58:06 UTC
(rev 76440)
@@ -2034,13 +2034,11 @@
MonoThread *thread=(MonoThread *)value;
/* Ignore background threads, we abort them later */
- mono_monitor_enter (thread->synch_lock);
+ /* Do not lock here since it is not needed and the caller holds
threads_lock */
if (thread->state & ThreadState_Background) {
THREAD_DEBUG (g_message ("%s: ignoring background
thread %"G_GSIZE_FORMAT, __func__, (gsize)thread->tid));
- mono_monitor_exit (thread->synch_lock);
return; /* just leave, ignore */
}
- mono_monitor_exit (thread->synch_lock);
if (mono_gc_is_finalizer_thread (thread)) {
THREAD_DEBUG (g_message ("%s: ignoring finalizer thread
%"G_GSIZE_FORMAT, __func__, (gsize)thread->tid));
_______________________________________________
Mono-patches maillist - [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches