From: Anthony Minessale Date: Mon, 14 Feb 2011 20:07:37 +0000 (-0600) Subject: fix regression in rtp stack trying to avoid broken clients who send the wrong payload... X-Git-Tag: v1.2-rc1~187^2~8^2~4 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=0bce777a4a06701798e426b13b8b7e0153836077;p=thirdparty%2Ffreeswitch.git fix regression in rtp stack trying to avoid broken clients who send the wrong payload type, we were eating the stun packets in jingle calls --- diff --git a/src/switch_rtp.c b/src/switch_rtp.c index 200f4f0dfa..faa79e35a2 100644 --- a/src/switch_rtp.c +++ b/src/switch_rtp.c @@ -2808,7 +2808,8 @@ static int rtp_common_read(switch_rtp_t *rtp_session, switch_payload_t *payload_ goto end; } - if (bytes && !switch_test_flag(rtp_session, SWITCH_RTP_FLAG_PROXY_MEDIA) && !switch_test_flag(rtp_session, SWITCH_RTP_FLAG_UDPTL) && + if (bytes && rtp_session->recv_msg.header.version == 2 && + !switch_test_flag(rtp_session, SWITCH_RTP_FLAG_PROXY_MEDIA) && !switch_test_flag(rtp_session, SWITCH_RTP_FLAG_UDPTL) && rtp_session->recv_msg.header.pt != 13 && rtp_session->recv_msg.header.pt != rtp_session->recv_te && (!rtp_session->cng_pt || rtp_session->recv_msg.header.pt != rtp_session->cng_pt) &&