Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/mono.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKoushik Dutta <koushd@gmail.com>2010-09-30 08:15:42 +0400
committerGeoff Norton <grompf@sublimeintervention.com>2010-10-01 20:33:18 +0400
commitc45cae8a26d869dc9db7513f0564229189ae03f7 (patch)
treea23cb453e48ea565b17eba17e3067116f788e673 /libgc/pthread_support.c
parent0e8579212966de44911c628212ac321538890e9d (diff)
Work around Android's pthread/kernel_id/fork bug to fix mono multithreading and GC_stop_world in processes that have been forked.
Diffstat (limited to 'libgc/pthread_support.c')
-rw-r--r--libgc/pthread_support.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/libgc/pthread_support.c b/libgc/pthread_support.c
index f0132044a09..f70d4f6e731 100644
--- a/libgc/pthread_support.c
+++ b/libgc/pthread_support.c
@@ -692,6 +692,9 @@ GC_thread GC_new_thread(pthread_t id)
}
if (result == 0) return(0);
result -> id = id;
+#ifdef PLATFORM_ANDROID
+ result -> kernel_id = gettid();
+#endif
result -> next = GC_threads[hv];
GC_threads[hv] = result;
GC_ASSERT(result -> flags == 0 && result -> thread_blocked == 0);