On Sep 22, 2010, at 12:52 AM, Rick Mann wrote:
Does iOS (and Mac OS X) clean up thread-local storage upon the completion of
an NSOperation? It seems dangerous to rely on every operation to clean up its
own mess. It also seems that an NSOperation should be able to pretend that it
owns the
On Sep 22, 2010, at 11:17:25, Julien Poissonnier wrote:
On Sep 22, 2010, at 12:52 AM, Rick Mann wrote:
Does iOS (and Mac OS X) clean up thread-local storage upon the completion of
an NSOperation? It seems dangerous to rely on every operation to clean up
its own mess. It also seems that
On Wed, Sep 22, 2010 at 11:31 AM, Rick Mann rm...@latencyzero.com wrote:
Pity. We have a singleton object that creates a subclass of NSOperation,
which then calls back a method on the singleton that's intended to be run on
a separate thread (provided indirectly by the NSOperation). That
not readily available, but won't be
too hard to make so.
If the NSOperation could've relied on getting a pristine threadDictionary, that
would've been very convenient (more specifically, if it could rely on the
NSOperation infrastructure to clean up the threadDictionary when the
NSOperation
not. The operation is actually not readily
available, but won't be too hard to make so.
If the NSOperation could've relied on getting a pristine threadDictionary,
that would've been very convenient (more specifically, if it could rely on
the NSOperation infrastructure to clean up the threadDictionary
Seems reasonable. The only problem I foresee is that if the system is
recycling threads for subsequent NSOperations, I don't think you'll get the
NSThreadWillExitNotification, because the thread itself never exits.
Do you care? In my case I only care that the MOC is appropriate for the
On Sep 22, 2010, at 17:00:13, Roland King wrote:
Seems reasonable. The only problem I foresee is that if the system is
recycling threads for subsequent NSOperations, I don't think you'll get the
NSThreadWillExitNotification, because the thread itself never exits.
Do you care? In my
not. The operation is actually not readily
available, but won't be too hard to make so.
If the NSOperation could've relied on getting a pristine threadDictionary,
that would've been very convenient (more specifically, if it could rely on
the NSOperation infrastructure to clean up the threadDictionary when
Does iOS (and Mac OS X) clean up thread-local storage upon the completion of an
NSOperation? It seems dangerous to rely on every operation to clean up its own
mess. It also seems that an NSOperation should be able to pretend that it owns
the thread on which it's running, and not have to worry