]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
fix regression in rtp stack trying to avoid broken clients who send the wrong payload...
authorAnthony Minessale <anthm@freeswitch.org>
Mon, 14 Feb 2011 20:07:37 +0000 (14:07 -0600)
committerAnthony Minessale <anthm@freeswitch.org>
Mon, 14 Feb 2011 20:07:46 +0000 (14:07 -0600)
src/switch_rtp.c

index 200f4f0dfa15301feed60054a8538d2f7fb731e3..faa79e35a255effc7806c2efbc6cccc67adf03d3 100644 (file)
@@ -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) &&