don't consider cng packets for rtp auto-adjust

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@15240 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
Anthony Minessale 2009-10-26 23:13:11 +00:00
parent cd0245be43
commit 3074415f6c
1 changed files with 2 additions and 1 deletions

View File

@ -1889,7 +1889,8 @@ static int rtp_common_read(switch_rtp_t *rtp_session, switch_payload_t *payload_
rtp_flush_read_buffer(rtp_session, SWITCH_RTP_FLUSH_ONCE);
}
if (bytes && switch_test_flag(rtp_session, SWITCH_RTP_FLAG_AUTOADJ) && switch_sockaddr_get_port(rtp_session->from_addr)) {
if (bytes && !(rtp_session->recv_msg.header.pt == rtp_session->cng_pt || rtp_session->recv_msg.header.pt == 13) &&
switch_test_flag(rtp_session, SWITCH_RTP_FLAG_AUTOADJ) && switch_sockaddr_get_port(rtp_session->from_addr)) {
if (++rtp_session->autoadj_tally >= 10) {
const char *tx_host;
const char *old_host;