Mercurial > sdl-ios-xcode
diff src/thread/SDL_thread.c @ 329:1d74ddc90cb2
Patrice's fixes for GNU Pthread support
author | Sam Lantinga <slouken@libsdl.org> |
---|---|
date | Mon, 01 Apr 2002 15:35:28 +0000 |
parents | f6ffac90895c |
children | b9f1ce709960 |
line wrap: on
line diff
--- a/src/thread/SDL_thread.c Sun Mar 31 04:07:05 2002 +0000 +++ b/src/thread/SDL_thread.c Mon Apr 01 15:35:28 2002 +0000 @@ -52,6 +52,12 @@ { int retval; +#ifdef ENABLE_PTH + if (!pth_init()) { + return -1; + } +#endif + retval = 0; /* Set the thread lock creation flag so that we can reuse an existing lock on the system - since this mutex never gets @@ -80,6 +86,10 @@ if ( mutex != NULL ) { SDL_DestroyMutex(mutex); } + +#ifdef ENABLE_PTH + pth_kill(); +#endif } /* Routines for manipulating the thread list */