ios - When I display the UIImagePickerController in a UIPopupviewController, it crashes -


i have in uipopupviewcontroller call ios camera, can take more 2 pictures sometime after first call crash.

-(void)imagepickercontroller:(uiimagepickercontroller *)picker didfinishpickingmediawithinfo:(nsdictionary *)info {      uiimage *image=[info objectforkey:uiimagepickercontrolleroriginalimage];     uiimagewritetosavedphotosalbum (image, nil, nil , nil);      [self dismissviewcontrolleranimated:no completion:nil];  }  -(ibaction)takephoto:(id)sender {      if ([uiimagepickercontroller issourcetypeavailable:uiimagepickercontrollersourcetypecamera]) {         uiimagepickercontroller *imagepicker=[[uiimagepickercontroller alloc]init];         imagepicker.delegate=self;         imagepicker.sourcetype=uiimagepickercontrollersourcetypecamera;         imagepicker.allowsediting=no;         [self presentmodalviewcontroller:imagepicker animated:no];      } } 

enter image description here


Comments

Popular posts from this blog

curl - PHP fsockopen help required -

HTTP/1.0 407 Proxy Authentication Required PHP -

java - More than one row with the given identifier was found: 1, for class: com.model.Diagnosis -