> Why would [NSArray initWithArray:copyItems:] be calling release on any > object?
When that method copies the objects in the supplied array, the copies start with a retain count of 1. Then, when each of these copies are placed into the new array, their retain count becomes 2. -initWithArray:copyItems then releases each of the copied objects once so that the array becomes the sole owner of them. (If it didn't do this, the copied objects would never get released, even when the resulting array is released.) _______________________________________________ Cocoa-dev mailing list ([email protected]) 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 [email protected]
