Re: NSMutableArray becomes NSString?
Re: NSMutableArray becomes NSString?
- Subject: Re: NSMutableArray becomes NSString?
- From: David Phillip Oster <email@hidden>
- Date: Fri, 13 Apr 2007 19:05:16 -0700
It is very easy to forget to write a copyWithZone: for your class,
have the program work for months, make a minor change to it, and have
the super class's default implementation get called, which blindly
copies all your ivars, dealloc an instance, and your dealloc releases
all the parts, and now original object is points at a dead part.
Mostly recently I've seen this with an NSTableView with a custom
cell. Since NSTableView's copying of your NSCell subclass happens
"under the hood", this bug is mysterious and hard to track down until
you've seen it.
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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:
This email sent to email@hidden