fix crash with RTCP xr

This commit is contained in:
Simon Morlat 2014-04-14 16:10:56 +02:00
parent 28f4a815f6
commit 80c1f93b95

View file

@ -2222,6 +2222,11 @@ void linphone_call_stop_video_stream(LinphoneCall *call) {
#endif
}
static void unset_rtp_profile(LinphoneCall *call, int i){
if (call->sessions[i].rtp_session)
rtp_session_set_profile(call->sessions[i].rtp_session,&av_profile);
}
void linphone_call_stop_media_streams(LinphoneCall *call){
if (call->audiostream || call->videostream) {
linphone_call_stop_audio_stream(call);
@ -2235,10 +2240,12 @@ void linphone_call_stop_media_streams(LinphoneCall *call){
if (call->audio_profile){
rtp_profile_destroy(call->audio_profile);
call->audio_profile=NULL;
unset_rtp_profile(call,0);
}
if (call->video_profile){
rtp_profile_destroy(call->video_profile);
call->video_profile=NULL;
unset_rtp_profile(call,1);
}
}