From cf3dc3ab92bab5535be707bf8aac265a5ec4b896 Mon Sep 17 00:00:00 2001 From: rfm Date: Sun, 6 Jan 2008 08:56:59 +0000 Subject: [PATCH] Clarify thread detach error git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@25880 72102866-910b-0410-8b05-ffd578937521 --- Source/NSThread.m | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Source/NSThread.m b/Source/NSThread.m index a5c43acfe..454001d40 100644 --- a/Source/NSThread.m +++ b/Source/NSThread.m @@ -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]]; } }