diff options
author | Zoltan Varga <vargaz@gmail.com> | 2010-04-08 02:42:28 +0400 |
---|---|---|
committer | Zoltan Varga <vargaz@gmail.com> | 2010-04-08 02:42:28 +0400 |
commit | 236bad85c405820bd31644d3dd109ea1eba16a3a (patch) | |
tree | 570a50684ec5a79f1ee747ff15672e204e047505 | |
parent | a76aad61b3dbebdd52f7f61420ffb0d3f00d42d6 (diff) |
2010-04-08 Zoltan Varga <vargaz@gmail.com>
* threads.c (mono_thread_suspend_all_other_threads): Call ensure_synch_cs_set ()
to avoid crashes on newly created threads.
svn path=/branches/mono-2-6/mono/; revision=155003
-rw-r--r-- | mono/metadata/ChangeLog | 5 | ||||
-rw-r--r-- | mono/metadata/threads.c | 2 |
2 files changed, 7 insertions, 0 deletions
diff --git a/mono/metadata/ChangeLog b/mono/metadata/ChangeLog index 1baa20ff3ff..ea164d85955 100644 --- a/mono/metadata/ChangeLog +++ b/mono/metadata/ChangeLog @@ -1,3 +1,8 @@ +2010-04-08 Zoltan Varga <vargaz@gmail.com> + + * threads.c (mono_thread_suspend_all_other_threads): Call ensure_synch_cs_set () + to avoid crashes on newly created threads. + 2010-04-07 Gonzalo Paniagua Javier <gonzalo@novell.com> * threadpool.c: decrement the domain threadpool jobs count. diff --git a/mono/metadata/threads.c b/mono/metadata/threads.c index a030a39d142..0e723735dcf 100644 --- a/mono/metadata/threads.c +++ b/mono/metadata/threads.c @@ -3232,6 +3232,8 @@ void mono_thread_suspend_all_other_threads (void) if (thread == NULL) continue; + + ensure_synch_cs_set (thread); EnterCriticalSection (thread->synch_cs); if ((thread->state & ThreadState_Suspended) != 0) { |