fix crash when receiving an ortp event without packet (temporary fix, a better one is coming)

This commit is contained in:
Simon Morlat 2017-09-11 21:10:26 +02:00
parent df7dccf4ad
commit 8ef0c3e2ff

View file

@ -4869,7 +4869,7 @@ void linphone_call_handle_stream_events(LinphoneCall *call, int stream_index){
if (stream_index == call->main_video_stream_index)
stats->estimated_download_bandwidth = (float)(evd->info.video_bandwidth_available)*1e-3;
} else if (evt == ORTP_EVENT_RTCP_PACKET_RECEIVED) {
if (rtcp_RTPFB_get_type(evd->packet) == RTCP_RTPFB_TMMBR) {
if (evd->packet && rtcp_RTPFB_get_type(evd->packet) == RTCP_RTPFB_TMMBR) {
linphone_call_notify_tmmbr_received(call, stream_index, (int)rtcp_RTPFB_tmmbr_get_max_bitrate(evd->packet));
}
}