On Apr 16, 2010, at 8:53 AM, Kyle Sluder wrote:

> Ross is probably right. You need to nil out weak references before releasing 
> things. Since you don't know if the NSXMLParser is going to live beyond your 
> releasing it, you don't know if it's going to later try messaging its 
> delegate. If that delegate has been dealloced, a crash ensues.

That’s true in general, but in this case he’s setting the parser’s delegate to 
itself. Which is weird, but should mean that the object can’t possibly outlive 
the delegate :)

—Jens_______________________________________________

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 arch...@mail-archive.com

Reply via email to