reset bandwidth controller between state and upon network changes

This commit is contained in:
Simon Morlat 2017-08-01 15:59:19 +02:00
parent 91922bcaab
commit 784f2bb8ef
2 changed files with 6 additions and 0 deletions

View file

@ -1721,6 +1721,9 @@ static void linphone_call_set_terminated(LinphoneCall *call){
if (call->chat_room){
call->chat_room->call = NULL;
}
if (lc->calls == NULL){
ms_bandwidth_controller_reset_state(lc->bw_controller);
}
}
/*function to be called at each incoming reINVITE, in order to adjust various local parameters to what is being offered by remote:

View file

@ -6218,6 +6218,9 @@ static void set_media_network_reachable(LinphoneCore* lc, bool_t is_media_reacha
bctbx_list_for_each(lc->calls, (MSIterateFunc)linphone_call_refresh_sockets);
}
linphone_core_repair_calls(lc);
if (lc->bw_controller){
ms_bandwidth_controller_reset_state(lc->bw_controller);
}
}
}