TT#14008 fix handling of possible NULL rtcp_sibling

closes #1302

Change-Id: I000337734400cf3a5b63fc5d51e9fd220be06c68
pull/1307/head
Richard Fuchs 4 years ago
parent cc09099660
commit 7b59f55457

@ -1268,7 +1268,7 @@ static int __init_streams(struct call_media *A, struct call_media *B, const stru
PS_CLEAR(a, RTCP);
else {
if (MEDIA_ISSET(A, ECHO) || MEDIA_ISSET(A, BLACKHOLE))
__add_sink_handler(&a->rtcp_sinks, a->rtcp_sibling);
{ /* RTCP sink handler added below */ }
else
__add_sink_handler(&a->rtcp_sinks, b);
PS_SET(a, RTCP);
@ -1283,8 +1283,11 @@ static int __init_streams(struct call_media *A, struct call_media *B, const stru
assert(la != NULL);
a = la->data;
if (MEDIA_ISSET(A, ECHO) || MEDIA_ISSET(A, BLACKHOLE))
if (MEDIA_ISSET(A, ECHO) || MEDIA_ISSET(A, BLACKHOLE)) {
__add_sink_handler(&a->rtcp_sinks, a);
if (MEDIA_ISSET(A, RTCP_MUX))
__add_sink_handler(&ax->rtcp_sinks, a);
}
else
__add_sink_handler(&a->rtcp_sinks, b);
PS_CLEAR(a, RTP);

@ -1694,7 +1694,8 @@ static void media_packet_rtcp_demux(struct packet_handler_ctx *phc)
int muxed_rtcp = rtcp_demux(&phc->s, phc->mp.media);
if (muxed_rtcp == 2) {
is_rtcp = 1;
phc->in_srtp = phc->mp.stream->rtcp_sibling; // use RTCP SRTP context
if (phc->mp.stream->rtcp_sibling)
phc->in_srtp = phc->mp.stream->rtcp_sibling; // use RTCP SRTP context
}
}
if (is_rtcp) {

Loading…
Cancel
Save