1
我得到一個EXC_BAD_ACCESS調用這段代碼在我的應用程序(新iPad)EXC_BAD_ACCESS用的UIImagePickerController和UIPopoverController
之後我得到的XCode幾乎沒有進行調試時,Xcode點我行代碼:
int retVal = UIApplicationMain(argc, argv, nil, nil);
我猜一個對象已經過早autoreleased,但爲什麼以及如何解決這個問題?
NSLog(@"OpenPhotoDialog");
UIImagePickerController *picker = [[UIImagePickerController alloc] init];
picker.delegate = self;
picker.sourceType = srcType;
UIDevice* thisDevice = [UIDevice currentDevice];
UIPopoverController *popover = [[UIPopoverController alloc] initWithContentViewController:picker] ;
popover.delegate = self;
[popover presentPopoverFromRect:self.view.frame inView:self.view permittedArrowDirections:UIPopoverArrowDirectionAny animated:YES];
對不起,我是新手用xcode和我遇到了同樣的問題,我將在哪裏設置nszombieEnabled是? – baste