mirror of
https://github.com/gnustep/libs-base.git
synced 2025-04-23 09:04:13 +00:00
fixup to work with old compilers
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@28750 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
40ee16100f
commit
77a7398d4a
1 changed files with 9 additions and 6 deletions
|
@ -803,6 +803,9 @@ static void *nsthreadLauncher(void* thread)
|
|||
|
||||
- (void) start
|
||||
{
|
||||
pthread_attr_t attr;
|
||||
pthread_t thr;
|
||||
|
||||
if (_active == YES)
|
||||
{
|
||||
[NSException raise: NSInternalInconsistencyException
|
||||
|
@ -838,14 +841,14 @@ static void *nsthreadLauncher(void* thread)
|
|||
_active = YES;
|
||||
|
||||
errno = 0;
|
||||
pthread_t thr;
|
||||
pthread_attr_t attr;
|
||||
pthread_attr_init(&attr);
|
||||
// Create this thread detached, because we never use the return state from
|
||||
// threads.
|
||||
/* Create this thread detached, because we never use the return state from
|
||||
* threads.
|
||||
*/
|
||||
pthread_attr_setdetachstate(&attr, PTHREAD_CREATE_DETACHED);
|
||||
// Set the stack size when the thread is created. Unlike the old setrlimit
|
||||
// code, this actually works.
|
||||
/* Set the stack size when the thread is created. Unlike the old setrlimit
|
||||
* code, this actually works.
|
||||
*/
|
||||
if (_stackSize > 0)
|
||||
{
|
||||
pthread_attr_setstacksize(&attr, _stackSize);
|
||||
|
|
Loading…
Reference in a new issue