AppDelegate.m文件包含
- (void)applicationDidEnterBackground:(UIApplication *)application
{
UIBackgroundTaskIdentifier taskID = [application beginBackgroundTaskWithExpirationHandler:^{
[application endBackgroundTask:taskID];
}];
}
Run Code Online (Sandbox Code Playgroud)
我不知道为什么我在gdb中收到此消息
无法endBackgroundTask:不存在标识符为1fd57580的后台任务,或者它可能已经结束。中断UIApplicationEndBackgroundTaskError()进行调试。