]> git.ipfire.org Git - thirdparty/asterisk.git/commit
res_pjsip_sdp_rtp: Fix return code from apply_negotiated_sdp_stream
authorGeorge Joseph <gjoseph@digium.com>
Wed, 30 Jan 2019 19:25:55 +0000 (12:25 -0700)
committerGeorge Joseph <gjoseph@digium.com>
Thu, 28 Feb 2019 17:34:28 +0000 (11:34 -0600)
commite436aab179e6dd8a6ff9508289b7e081e5fdf032
tree835061a6a4d49f11b340cc56251ef0ffc2515495
parent735c0a39424a725aa70a6067d769cbd0b7531ccd
res_pjsip_sdp_rtp:  Fix return code from apply_negotiated_sdp_stream

apply_negotiated_sdp_stream was returning a "1" when no joint
capabilities were found on an outgoing call instead of a "-1".
This indicated to res_pjsip_session that the handler DID handle
the sdp when in fact it didn't.  Without the appropriate setup,
a subsequent media frame coming in would have an invalid stream_num
and cause a seg fault when the stream was attempted to be retrieved.

apply_negotiated_sdp_stream now returns the correct "-1" and any
media is now discarded before it reaches the core stream processing.

ASTERISK-28260
Reported by: Sotiris Ganouris

Change-Id: Ia095cb16b4862f2f6ad6d2d2a77453fa2542371f
res/res_pjsip_sdp_rtp.c