mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-01-11 08:54:35 +08:00
* gthr-win32.h [__GTHREAD_HIDE_WIN32API]
(__gthr_win32_mutex_destroy): Declare. [__GTHREAD_HIDE_WIN32API] (__gthread_mutex_destroy): Use __gthr_win32_mutex_destroy * config/i386/gthr-win32.c (__gthr_win32_mutex_destroy): Define. From-SVN: r132853
This commit is contained in:
parent
2c8e955e85
commit
c262f705cb
@ -1,3 +1,11 @@
|
||||
2008-03-04 Danny Smith <dannysmith@users.sourceforge.net>
|
||||
|
||||
* gthr-win32.h [__GTHREAD_HIDE_WIN32API]
|
||||
(__gthr_win32_mutex_destroy): Declare.
|
||||
[__GTHREAD_HIDE_WIN32API] (__gthread_mutex_destroy): Use
|
||||
__gthr_win32_mutex_destroy.
|
||||
* config/i386/gthr-win32.c (__gthr_win32_mutex_destroy): Define.
|
||||
|
||||
2008-03-03 Jan Hubicka <jh@suse.cz>
|
||||
|
||||
PR c++/35262
|
||||
|
@ -151,6 +151,12 @@ __gthr_win32_mutex_init_function (__gthread_mutex_t *mutex)
|
||||
mutex->sema = CreateSemaphore (NULL, 0, 65535, NULL);
|
||||
}
|
||||
|
||||
void
|
||||
__gthr_win32_mutex_destroy (__gthread_mutex_t *mutex)
|
||||
{
|
||||
CloseHandle ((HANDLE) mutex->sema);
|
||||
}
|
||||
|
||||
int
|
||||
__gthr_win32_mutex_lock (__gthread_mutex_t *mutex)
|
||||
{
|
||||
|
@ -423,6 +423,7 @@ extern int __gthr_win32_recursive_mutex_lock (__gthread_recursive_mutex_t *);
|
||||
extern int
|
||||
__gthr_win32_recursive_mutex_trylock (__gthread_recursive_mutex_t *);
|
||||
extern int __gthr_win32_recursive_mutex_unlock (__gthread_recursive_mutex_t *);
|
||||
extern void __gthr_win32_mutex_destroy (__gthread_mutex_t *);
|
||||
|
||||
static inline int
|
||||
__gthread_once (__gthread_once_t *once, void (*func) (void))
|
||||
@ -463,6 +464,12 @@ __gthread_mutex_init_function (__gthread_mutex_t *mutex)
|
||||
__gthr_win32_mutex_init_function (mutex);
|
||||
}
|
||||
|
||||
static inline void
|
||||
__gthread_mutex_destroy (__gthread_mutex_t *mutex)
|
||||
{
|
||||
__gthr_win32_mutex_destroy (mutex);
|
||||
}
|
||||
|
||||
static inline int
|
||||
__gthread_mutex_lock (__gthread_mutex_t *mutex)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user