LinphoneManager.m: do not erase core in shutdown

This commit is contained in:
Gautier Pelloux-Prayer 2016-01-26 15:49:37 +01:00
parent 81bd7e564c
commit 481988084e

View file

@ -781,14 +781,10 @@ static void linphone_iphone_global_state_changed(LinphoneCore *lc, LinphoneGloba
dictionaryWithObjectsAndKeys:[NSNumber numberWithInt:state], @"state",
[NSString stringWithUTF8String:message ? message : ""], @"message", nil];
if (state == LinphoneGlobalShutdown) {
theLinphoneCore = nil;
} else {
// dispatch the notification asynchronously
dispatch_async(dispatch_get_main_queue(), ^(void) {
[NSNotificationCenter.defaultCenter postNotificationName:kLinphoneGlobalStateUpdate object:self userInfo:dict];
});
}
// dispatch the notification asynchronously
dispatch_async(dispatch_get_main_queue(), ^(void) {
[NSNotificationCenter.defaultCenter postNotificationName:kLinphoneGlobalStateUpdate object:self userInfo:dict];
});
}
- (void)globalStateChangedNotificationHandler:(NSNotification *)notif {