Re: [iphone] Release Navigation View Controller Question
Re: [iphone] Release Navigation View Controller Question
- Subject: Re: [iphone] Release Navigation View Controller Question
- From: Alexander Spohr <email@hidden>
- Date: Mon, 18 Jan 2010 23:58:41 +0100
Am 18.01.2010 um 14:40 schrieb Philip Vallone:
> Hi this is a follow up question on memory management. In my class BrowseViewController, I have a UITableView and 2 NSMutableArrays.
>
> @interface BrowseViewController : UIViewController <UIActionSheetDelegate> {
> IBOutlet UITableView *tableView;
> NSMutableArray *tableList;
> NSMutableArray *cfrTitleList;
> }
> @property(nonatomic, retain) UITableView *tableView;
>
> @end
>
> Now the BrowseViewController has a few "child" Navigational controllers. This allows the user to drill down. My question is, in the BrowseViewController.m dealloc method, if I release the two NSMutableArrays, I receive the error “EXC_BAD_ACCESS”.
Then you forgot to retain them when you should.
Show code where they are assigned if you can’t fix it.
> If I don't release the NSMutableArrays, does this mean the navigationController takes ownership of the NSMutableArrays?
No, it does not even know they exist. How should it?
atze
_______________________________________________
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