Clarify thread detach error

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@25880 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
Richard Frith-MacDonald 2008-01-06 08:56:59 +00:00
parent 7a9fd523b6
commit 9e1a7d5870

View file

@ -912,12 +912,13 @@ pthread_detach(pthread_self());
*/
_active = YES;
errno = 0;
if (objc_thread_detach(@selector(main), self, nil) == NULL)
{
_active = NO;
RELEASE(self);
[NSException raise: NSInternalInconsistencyException
format: @"Unable to detach thread (perhaps %@)",
format: @"Unable to detach thread (last error %@)",
[NSError _last]];
}
}