For an NSOperation subclass with a call to NSRunloop in the start method as below:
NSRunLoop * runloop = [NSRunLoop currentRunLoop];
while (!stopRunloop && [runloop runMode:NSDefaultRunLoopMode beforeDate:[NSDate distantFuture]]);
The nsoperation is added to an NSOperationQueue [and not main queue]. I need runloop so as to get callback from a library doing some background tasks. My questions are as below: 1. Does the thread that prepares NSOperation copies all its data to the thread in which NSOperation runs [when start method execution begins] ? 2. Why the above while loop not able to terminate despite the stopRunloop is getting updated from library callback with value YES ? 3. Does a start method also need an @autoreleasepool usage ?
Thanks