Re: Problem instantiating an array
Re: Problem instantiating an array
- Subject: Re: Problem instantiating an array
- From: Graham Cox <email@hidden>
- Date: Tue, 7 Dec 2010 19:40:20 +1100
On 07/12/2010, at 5:35 PM, Ken Thomases wrote:
>> gameColumns = [NSArray arrayWithObjects:allColumns count: boardDimension];
Another issue with this line is that, assuming 'gameColumns' is an instance variable of the object, the array will be autoreleased, leaving the variable pointing at deallocated memory, which will surely crash later.
--Graham
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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:
This email sent to email@hidden