[asterisk-dev] [Code Review] 3788: media formats: Fix crash in chan_sip's sip_new when offered only non-audio media streams

Matt Jordan reviewboard at asterisk.org
Tue Jul 15 14:42:02 CDT 2014


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviewboard.asterisk.org/r/3788/
-----------------------------------------------------------

(Updated July 15, 2014, 7:42 p.m.)


Status
------

This change has been marked as submitted.


Review request for Asterisk Developers, Corey Farrell, Joshua Colp, and opticron.


Changes
-------

Committed in revision 418710


Repository: Asterisk


Description
-------

When offered only non-audio media streams, chan_sip will currently crash. This is due to its preferred codec logic attempting to grab the preferred audio format and not checking to see if it is NULL.

This patch keeps the audio logic (as it mirrors closely what occurs now), but falls back to getting the preferred format of any type if the audio lookup fails to find a format.


Diffs
-----

  ./team/group/media_formats-reviewed-trunk/channels/chan_sip.c 418614 

Diff: https://reviewboard.asterisk.org/r/3788/diff/


Testing
-------

The SDP_offer_answer test in the testsuite stopped crashing.


Thanks,

Matt Jordan

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-dev/attachments/20140715/2737ce8f/attachment.html>


More information about the asterisk-dev mailing list