Unlock the pool for all threads leaving it. (#78348) glib-2-0-branchpoint
authorSebastian Wilhelmi <wilhelmi@ira.uka.de>
Sat, 13 Apr 2002 10:08:31 +0000 (10:08 +0000)
committerSebastian Wilhelmi <wilhelmi@src.gnome.org>
Sat, 13 Apr 2002 10:08:31 +0000 (10:08 +0000)
2002-04-13  Sebastian Wilhelmi  <wilhelmi@ira.uka.de>

* glib/gthreadpool.c (g_thread_pool_thread_proxy): Unlock the pool
for all threads leaving it. (#78348)

ChangeLog
ChangeLog.pre-2-10
ChangeLog.pre-2-12
ChangeLog.pre-2-2
ChangeLog.pre-2-4
ChangeLog.pre-2-6
ChangeLog.pre-2-8
glib/gthreadpool.c

index 6c0ddfc..b953800 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2002-04-13  Sebastian Wilhelmi  <wilhelmi@ira.uka.de>
+
+       * glib/gthreadpool.c (g_thread_pool_thread_proxy): Unlock the pool
+       for all threads leaving it. (#78348)
+
 2002-04-11  Matthias Clasen  <maclas@gmx.de>
 
        * tests/patterntest.c: Remove manual UTF-8 -> Latin1 conversion for
index 6c0ddfc..b953800 100644 (file)
@@ -1,3 +1,8 @@
+2002-04-13  Sebastian Wilhelmi  <wilhelmi@ira.uka.de>
+
+       * glib/gthreadpool.c (g_thread_pool_thread_proxy): Unlock the pool
+       for all threads leaving it. (#78348)
+
 2002-04-11  Matthias Clasen  <maclas@gmx.de>
 
        * tests/patterntest.c: Remove manual UTF-8 -> Latin1 conversion for
index 6c0ddfc..b953800 100644 (file)
@@ -1,3 +1,8 @@
+2002-04-13  Sebastian Wilhelmi  <wilhelmi@ira.uka.de>
+
+       * glib/gthreadpool.c (g_thread_pool_thread_proxy): Unlock the pool
+       for all threads leaving it. (#78348)
+
 2002-04-11  Matthias Clasen  <maclas@gmx.de>
 
        * tests/patterntest.c: Remove manual UTF-8 -> Latin1 conversion for
index 6c0ddfc..b953800 100644 (file)
@@ -1,3 +1,8 @@
+2002-04-13  Sebastian Wilhelmi  <wilhelmi@ira.uka.de>
+
+       * glib/gthreadpool.c (g_thread_pool_thread_proxy): Unlock the pool
+       for all threads leaving it. (#78348)
+
 2002-04-11  Matthias Clasen  <maclas@gmx.de>
 
        * tests/patterntest.c: Remove manual UTF-8 -> Latin1 conversion for
index 6c0ddfc..b953800 100644 (file)
@@ -1,3 +1,8 @@
+2002-04-13  Sebastian Wilhelmi  <wilhelmi@ira.uka.de>
+
+       * glib/gthreadpool.c (g_thread_pool_thread_proxy): Unlock the pool
+       for all threads leaving it. (#78348)
+
 2002-04-11  Matthias Clasen  <maclas@gmx.de>
 
        * tests/patterntest.c: Remove manual UTF-8 -> Latin1 conversion for
index 6c0ddfc..b953800 100644 (file)
@@ -1,3 +1,8 @@
+2002-04-13  Sebastian Wilhelmi  <wilhelmi@ira.uka.de>
+
+       * glib/gthreadpool.c (g_thread_pool_thread_proxy): Unlock the pool
+       for all threads leaving it. (#78348)
+
 2002-04-11  Matthias Clasen  <maclas@gmx.de>
 
        * tests/patterntest.c: Remove manual UTF-8 -> Latin1 conversion for
index 6c0ddfc..b953800 100644 (file)
@@ -1,3 +1,8 @@
+2002-04-13  Sebastian Wilhelmi  <wilhelmi@ira.uka.de>
+
+       * glib/gthreadpool.c (g_thread_pool_thread_proxy): Unlock the pool
+       for all threads leaving it. (#78348)
+
 2002-04-11  Matthias Clasen  <maclas@gmx.de>
 
        * tests/patterntest.c: Remove manual UTF-8 -> Latin1 conversion for
index 020a119..25a9cd0 100644 (file)
@@ -134,10 +134,9 @@ g_thread_pool_thread_proxy (gpointer data)
          watcher = TRUE;
        }
 
-      
       if (goto_global_pool)
        {
-         pool->num_threads--; 
+         pool->num_threads--;
 
          if (!pool->running && !pool->waiting)
            {
@@ -146,9 +145,11 @@ g_thread_pool_thread_proxy (gpointer data)
                  g_async_queue_unlock (pool->queue);
                  g_thread_pool_free_internal (pool);
                }               
-             else if (len == - pool->num_threads)
+             else 
                {
-                 g_thread_pool_wakeup_and_stop_all (pool);
+                 if (len == - pool->num_threads)
+                   g_thread_pool_wakeup_and_stop_all (pool);
+
                  g_async_queue_unlock (pool->queue);
                }
            }