I have a piece of code that will only run once in the background when the application loads. I don't want to worry about NSOperationQueue * memory management, can I do autoreleasethis?
NSOperationQueue *queue = [[NSOperationQueue alloc] init];
NSInvocationOperation *op = [[NSInvocationOperation alloc] initWithTarget:self selector:@selector(oneTimeTask) object:nil];
[queue addOperation:op];
[op release];
[queue autorelease];
thank
source
share