fix crash when stop lc too early

This commit is contained in:
Danmei Chen 2020-05-22 16:42:42 +02:00
parent 3e191259aa
commit 8d54620295

View file

@ -81,9 +81,11 @@
linphone_call_enable_camera(call, false);
}
[LinphoneManager.instance enterBackgroundMode];
[LinphoneManager.instance.fastAddressBook clearFriends];
[CoreManager.instance stopLinphoneCore];
dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(0.3 * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{
[LinphoneManager.instance enterBackgroundMode];
[LinphoneManager.instance.fastAddressBook clearFriends];
[CoreManager.instance stopLinphoneCore];
});
}
- (void)applicationDidBecomeActive:(UIApplication *)application {