Re: alloc init thread safe?
Re: alloc init thread safe?
- Subject: Re: alloc init thread safe?
- From: David Carlisle <email@hidden>
- Date: Thu, 8 Mar 2007 11:43:22 -0700
I'm using NSThread detachThreadSelector. Nothing out of the ordinary.
But now I find I have a BOOL method that is rarely and randomly
returning NO when the only exit to the method is "return YES;" so I
have some strange problem somewhere. It turned out that the method
didn't need to be BOOL, but the result is checked anyway.
It's not something that is being picked up by NSZombie.
On Mar 8, 2007, at 11:09 AM, Shawn Erickson wrote:
On 3/8/07, David Carlisle <email@hidden> wrote:
I can't see a way around believing alloc isn't thread safe in this
case for some reason.
I meant to ask specifically... how are you creating your secondary
threads? If you aren't creating them using NSThread have you taken
steps to force the Cocoa framework into multi-threaded mode? (as Chris
outlined in his email)
Review...
<http://developer.apple.com/documentation/Cocoa/Conceptual/
Multithreading/articles/CocoaDetaching.html#//apple_ref/doc/uid/
20000738-125024-BAJGFJED>
-Shawn
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden