我已經重寫我的UITableViewController
didSelectRowAtIndexPath
方法方式如下:EXC_BAD_ACCESS在didSelectRowAtIndexPath方法
- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
{
PhotoListViewController *photosViewController = [[PhotoListViewController alloc] initWithStyle:UITableViewStylePlain];
NSLog(@"Let's see what we got %d", [[fetchedResultsController fetchedObjects] count]);
Person *person = [fetchedResultsController objectAtIndexPath:indexPath];
photosViewController.person = person;
photosViewController.title = [person.name stringByAppendingString:@"'s Photos"];
[self.navigationController pushViewController:photosViewController animated:YES];
[photosViewController release];
}
每當我嘗試訪問fetchedResultsController
我得到的崩潰,我將在這裏:
我只發佈它在我的dealloc
方法
請發佈任何相關的崩潰信息。控制檯輸出,崩潰日誌,並確保NSZombieEnabled是在 – Joe
我沒有得到崩潰的信息,它只是暫停在我的主線上int retVal = UIApplicationMain(argc,argv,nil,nil);並說EXC_BAD_ACCESS – 8vius
你能告訴我如何設置NSZombieEnabled? – 8vius