fix useless media restarts due to ICE reINVITE.

This commit is contained in:
Simon Morlat 2016-10-21 11:02:19 +02:00
parent 33f515d1ee
commit 596a6292c1
3 changed files with 13 additions and 3 deletions

View file

@ -884,6 +884,14 @@ void linphone_call_make_local_media_description(LinphoneCall *call) {
transfer_already_assigned_payload_types(old_md,md);
call->localdesc_changed=sal_media_description_equals(md,old_md);
sal_media_description_unref(old_md);
if (call->params->internal_call_update){
/*
* An internal call update (ICE reINVITE) is not expected to modify the actual media stream parameters.
* However, the localdesc may change between first INVITE and ICE reINVITE, for example if the remote party has declined a video stream.
* We use the internal_call_update flag to prevent trigger an unnecessary media restart.
*/
call->localdesc_changed = 0;
}
}
force_streams_dir_according_to_state(call, md);
}

View file

@ -3566,10 +3566,12 @@ int linphone_core_start_update_call(LinphoneCore *lc, LinphoneCall *call){
#endif //BUILD_UPNP
if (call->params->in_conference){
subject="Conference";
}else if (call->params->internal_call_update){
subject="ICE processing concluded";
}else if (!no_user_consent){
subject="Media change";
}else{
subject="Refreshing";
}else{
subject="Media change";
}
linphone_core_notify_display_status(lc,_("Modifying call parameters..."));
if (!lc->sip_conf.sdp_200_ack){

@ -1 +1 @@
Subproject commit 354927db3ce0b45bdd25cb4574dd95562fcbf8b1
Subproject commit ff857a68653beae24fff732b1afbdd082eb589cc