here I have a tableView in my viewController, and it's like this:
//.h
...
UITableView *aTable;
...
@property (nonatomic, retain) UITableView *aTable;
//.m
@synthesize aTable;
...
self.aTable = nil; // in viewDidUnload
[aTable release]; // in dealloc
...
and now, in the viewDidLoad method I have to initialize this talbe, so I did this
// viewDidLoad
...
self.aTable = [[UITableView alloc] initWithFrame:xxxxx];
...
but when I analyze this, it reminds me that in the viewDidLoad,
there maybe a potential leak of memory of this "aTable",
but I guess I am about to release it in the dealloc, so why is there still a leak of memory?
it is about the "retain" property?
do I have to add an autorelease to the code where alloc and initiate this tableView?
Thanks a lot!