> There is a chance that my calls to performSelectorOnMainThread can have > waitUntilDone:NO > > I use [myNSData writeToFile:path atomically:YES] > > NSFileHandle and NSFileManager are shown as not thread safe, but NSData > is... Perhaps it is ok, but I would think NSData uses one or both of the > above. > > One of the calls to performSelectorOnMainThread may need to wait on a file > download, but I think that could be a different lock.
I think you're missing the point: once the thread has detected that it should quit, it calls as its last statement performSelectorOnMainThread for whatever needs to be done on the main thread, and then just falls off the end. When the the selector is called in the main thread, you know at that point that the thread is done--there's no need to wait for the thread to terminate. What do you need done that is not done by the sample code that I posted? -- Scott Ribe [EMAIL PROTECTED] http://www.killerbytes.com/ (303) 722-0567 voice _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) 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]