From 9ad8beaa148c78e04a2aac3c5ad6d85567d31b01 Mon Sep 17 00:00:00 2001 From: Benny Prijono Date: Wed, 30 Nov 2011 09:34:33 +0000 Subject: Fixed problem with selecting audio codec if rtpmap is omitted from the SDP for the static PT (re #1393, thanks RĂ©gis Montoya for the fix!) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit git-svn-id: http://svn.pjsip.org/repos/pjproject/trunk@3890 74dad513-b988-da41-8d7b-12977e46ad98 --- pjmedia/src/pjmedia/stream.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/pjmedia/src/pjmedia/stream.c b/pjmedia/src/pjmedia/stream.c index 1da09c70..52a6a73c 100644 --- a/pjmedia/src/pjmedia/stream.c +++ b/pjmedia/src/pjmedia/stream.c @@ -2833,6 +2833,12 @@ static pj_status_t get_audio_codec_info_param(pjmedia_stream_info *si, return PJMEDIA_EINVALIDPT; pt = pj_strtoul(&local_m->desc.fmt[fmti]); + if (pt < 96) { + /* This is known static PT. Skip rtpmap checking because it is + * optional. */ + break; + } + attr = pjmedia_sdp_media_find_attr(local_m, &ID_RTPMAP, &local_m->desc.fmt[fmti]); if (attr == NULL) -- cgit v1.2.3