projects
/
platform
/
upstream
/
glib.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
cfa1d05
)
make g_thread_init_glib() idempotent
author
Ryan Lortie
<desrt@desrt.ca>
Wed, 31 Aug 2011 22:07:55 +0000
(18:07 -0400)
committer
Ryan Lortie
<desrt@desrt.ca>
Fri, 9 Sep 2011 16:47:40 +0000
(12:47 -0400)
glib/gthread.c
patch
|
blob
|
history
diff --git
a/glib/gthread.c
b/glib/gthread.c
index
9fc5254
..
62902b4
100644
(file)
--- a/
glib/gthread.c
+++ b/
glib/gthread.c
@@
-925,6
+925,13
@@
G_LOCK_DEFINE_STATIC (g_thread);
void
g_thread_init_glib (void)
{
+ static gboolean already_done;
+
+ if (already_done)
+ return;
+
+ already_done = TRUE;
+
_g_thread_impl_init ();
/* We let the main thread (the one that calls g_thread_init) inherit