Commit 60b34eb3 authored by Sylvain Berfini's avatar Sylvain Berfini 🎩

Refresh registers when entering foreground if default proxy config registration state is failed

parent c6cbe98e
......@@ -225,6 +225,15 @@ void Core::enterBackground () {
void Core::enterForeground () {
L_D();
d->notifyEnteringForeground();
LinphoneProxyConfig *proxy_config = linphone_core_get_default_proxy_config(getCCore());
if (proxy_config) {
LinphoneRegistrationState state = linphone_proxy_config_get_state(proxy_config);
if (state == LinphoneRegistrationState::LinphoneRegistrationFailed) {
lWarning() << "Default proxy config state is failed when entering foreground, refreshing registers";
linphone_core_refresh_registers(getCCore());
}
}
}
bool Core::isInBackground () {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment