The [super dealloc] in dealloc of UIViewController giving problem in iPad -
i working on application pushing 1 view controller on uinavigationcontroller , releasing navigation controller retains it.when poping view controller dealloc
method being called expected problem app getting crashed.if observe in gdb enabling nszombie
saying -[myviewcontroller iskindofclass:]: message sent deallocated instance 0x6847a00
.if remove [super dealloc]
from view controller's dealloc
method working fine.i have nothing else in dealloc method except [super dealloc].what problem here, can 1 please help.the code snippet below:
myviewcontroller *myviewcontroller = [[myviewcontroller alloc] initwithnibname:nil bundle:nil]; myviewcontroller.path = selectedpath; //very important set path here myviewcontroller.parentviewcontroller = self; [self cleanbookshelf]; [self.navigationcontroller pushviewcontroller:myviewcontroller animated:no]; [myviewcontroller release]; [indicatorview removefromsuperview]; [loadingindicator stopanimating];
and poping in 1 action method of myviewcontroller as
-(ibaction)goback:(uibutton*)sender{ [self.navigationcontroller popviewcontrolleranimated:yes]; }
just guessing, suspect problem line:
myviewcontroller.parentviewcontroller = self;
uiviewcontroller's parentviewcontroller
property marked readonly
, , i'd take strong message shouldn't mess it.
Comments
Post a Comment