On Tue, May 26, 2009 at 10:41 AM, Dave DeLong <[email protected]> wrote: > All of this works fine. My question has to do with memory management and > thread cleanup.
I'm snipping out most of your message because I think that all will make sense once you know this one fact: NSThread retains the target and argument of the thread until the thread terminates. Since NSThread takes ownership of those objects when you create the thread, you can rely on them to stay alive as long as the thread is running. Thus, perform memory management as usual, and don't worry about your thread object getting deallocated before you finish executing the thread, because it can't happen unless you've violated the memory-management rules and over-released something. Mike _______________________________________________ Cocoa-dev mailing list ([email protected]) Please 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: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to [email protected]
