NSOperation should clear its completion block after it fires

Originator:doug
Number:rdar://12519921 Date Originated:
Status:Open Resolved:
Product:Mac OS X SDK Product Version:10.8
Classification:Enhancement Reproducible:Always
 
Summary:
NSOperation doesn't nil its completion block after firing it, leading to a cycle if the op is referenced in it's own completion block. If it did nil the completion block then cycles from referencing the op in its own completion block would be avoided.

Steps to Reproduce:
Reference an op in its own completion block and note that it's a cycle.

Expected Results:
Completion block to be niled after firing, breaking the cycle

Actual Results:
Cycle

Regression:


Notes:
Sample app: http://cl.ly/2u0h1Y1L3e1F

Comments

Duped: rdar://12520067

By krismarkel at Oct. 17, 2012, 7:17 p.m. (reply...)

Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!