* src/threads/native/threads.c (threads_impl_preinit): Initialize
authortwisti <none@none>
Wed, 30 May 2007 20:30:00 +0000 (20:30 +0000)
committertwisti <none@none>
Wed, 30 May 2007 20:30:00 +0000 (20:30 +0000)
mutex_threads_list.
(threads_impl_table_init): Removed.
(threads_impl_table_init, threads_list_unlock): Fixed debug message.

* src/threads/threads-common.h (threads_impl_table_init): Removed.

src/threads/native/threads.c
src/threads/threads-common.h

index 0ab07cf9b9a79c63b971efcdc4c267283a609a4e..57f8401d2fd048abc3383b6223b0edc005a5b597 100644 (file)
@@ -22,7 +22,7 @@
    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
    02110-1301, USA.
 
-   $Id: threads.c 7981 2007-05-30 19:43:36Z twisti $
+   $Id: threads.c 7984 2007-05-30 20:30:00Z twisti $
 
 */
 
@@ -702,6 +702,10 @@ void threads_impl_preinit(void)
        pthread_mutex_init(&mutex_join, NULL);
        pthread_cond_init(&cond_join, NULL);
 
+       /* initialize the threads-list mutex */
+
+       pthread_mutex_init(&mutex_threads_list, NULL);
+
 #if !defined(HAVE___THREAD)
        pthread_key_create(&threads_current_threadobject_key, NULL);
 #endif
@@ -710,18 +714,6 @@ void threads_impl_preinit(void)
 }
 
 
-/* threads_table_lock **********************************************************
-
-   Initialize threads table mutex.
-
-*******************************************************************************/
-
-void threads_impl_table_init(void)
-{
-       pthread_mutex_init(&mutex_threads_list, NULL);
-}
-
-
 /* threads_list_lock ***********************************************************
 
    Enter the threads table mutex.
@@ -736,7 +728,7 @@ void threads_impl_table_init(void)
 void threads_list_lock(void)
 {
        if (pthread_mutex_lock(&mutex_threads_list) != 0)
-               vm_abort("threads_table_lock: pthread_mutex_lock failed: %s",
+               vm_abort("threads_list_lock: pthread_mutex_lock failed: %s",
                                 strerror(errno));
 }
 
@@ -750,7 +742,7 @@ void threads_list_lock(void)
 void threads_list_unlock(void)
 {
        if (pthread_mutex_unlock(&mutex_threads_list) != 0)
-               vm_abort("threads_table_unlock: pthread_mutex_unlock failed: %s",
+               vm_abort("threads_list_unlock: pthread_mutex_unlock failed: %s",
                                 strerror(errno));
 }
 
index 0bbf2b2bde1568c3cfe1c0b8f74c049c1a4175e9..a440f12d54891e3e3189fbee693ee3178368154f 100644 (file)
@@ -22,7 +22,7 @@
    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
    02110-1301, USA.
 
-   $Id: threads-common.h 7963 2007-05-24 10:21:16Z twisti $
+   $Id: threads-common.h 7984 2007-05-30 20:30:00Z twisti $
 
 */
 
@@ -102,7 +102,6 @@ void          threads_print_stacktrace(void);
 
 void          threads_impl_preinit(void);
 
-void          threads_impl_table_init(void);
 void          threads_list_lock(void);
 void          threads_list_unlock(void);