diff --git a/src/org/linphone/LinphoneActivity.java b/src/org/linphone/LinphoneActivity.java index 7af9345f2..161fe94ce 100644 --- a/src/org/linphone/LinphoneActivity.java +++ b/src/org/linphone/LinphoneActivity.java @@ -646,7 +646,8 @@ public class LinphoneActivity extends FragmentActivity implements public void updateStatusFragment(StatusFragment fragment) { statusFragment = fragment; - if (LinphoneManager.getLc().getDefaultProxyConfig() != null) { + LinphoneCore lc = LinphoneManager.getLcIfManagerNotDestroyedOrNull(); + if (lc != null && lc.getDefaultProxyConfig() != null) { statusFragment.registrationStateChanged(LinphoneManager.getLc().getDefaultProxyConfig().getState()); } } @@ -774,7 +775,9 @@ public class LinphoneActivity extends FragmentActivity implements @Override public void onRegistrationStateChanged(RegistrationState state) { if (statusFragment != null) { - statusFragment.registrationStateChanged(state); + LinphoneCore lc = LinphoneManager.getLcIfManagerNotDestroyedOrNull(); + if (lc != null && lc.getDefaultProxyConfig() != null) + statusFragment.registrationStateChanged(lc.getDefaultProxyConfig().getState()); } }