From b128c5ef491058b71c5f868b13aaafb26ac8aff7 Mon Sep 17 00:00:00 2001 From: Benjamin Kosnik Date: Thu, 14 Sep 2006 22:28:55 +0000 Subject: [PATCH] concurrence.h (__mutex::__mutex): Pass address of mutex to *_MUTEX_INIT_FUNCTION. 2006-09-14 Benjamin Kosnik * include/bits/concurrence.h (__mutex::__mutex): Pass address of mutex to *_MUTEX_INIT_FUNCTION. From-SVN: r116954 --- libstdc++-v3/ChangeLog | 7 ++++++- libstdc++-v3/include/ext/concurrence.h | 4 ++-- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog index 3d5f8798bd5..d40bee2a189 100644 --- a/libstdc++-v3/ChangeLog +++ b/libstdc++-v3/ChangeLog @@ -1,4 +1,9 @@ -2006-09-13 Benjamin Kosnik +2006-09-14 Benjamin Kosnik + + * include/bits/concurrence.h (__mutex::__mutex): Pass address of + mutex to *_MUTEX_INIT_FUNCTION. + +2006-09-13 Benjamin Kosnik * include/bits/atomicity.h: Move to... * include/ext/atomicity.h: ...here. diff --git a/libstdc++-v3/include/ext/concurrence.h b/libstdc++-v3/include/ext/concurrence.h index 54d21e595ae..5f71115293b 100644 --- a/libstdc++-v3/include/ext/concurrence.h +++ b/libstdc++-v3/include/ext/concurrence.h @@ -81,7 +81,7 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx) __gthread_mutex_t __tmp = __GTHREAD_MUTEX_INIT; _M_mutex = __tmp; #else - __GTHREAD_MUTEX_INIT_FUNCTION(_M_mutex); + __GTHREAD_MUTEX_INIT_FUNCTION(&_M_mutex); #endif } #endif @@ -128,7 +128,7 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx) __gthread_recursive_mutex_t __tmp = __GTHREAD_RECURSIVE_MUTEX_INIT; _M_mutex = __tmp; #else - __GTHREAD_RECURSIVE_MUTEX_INIT_FUNCTION(_M_mutex); + __GTHREAD_RECURSIVE_MUTEX_INIT_FUNCTION(&_M_mutex); #endif } #endif