我正在使用以下代码(使用 ARC)呈现 UIActivityViewController:
- (IBAction)share:(id)sender {
UIActivityViewController *activityController = [[UIActivityViewController alloc]
initWithActivityItems:[NSArray arrayWithObjects:@"Cat",@"Dog" , nil]
applicationActivities:nil];
[self presentViewController:activityController animated:YES completion:nil];}
使用仪器“泄漏”在 iphone 模拟器上运行程序。呈现视图并单击取消后:在以下行出现泄漏(100%):
[self presentViewController:activityController animated:YES completion:nil];
我究竟做错了什么?