This commit is contained in:
Anthony Minessale 2011-03-22 12:07:06 -05:00
parent 26f5ebd47d
commit fd6089014e
1 changed files with 44 additions and 47 deletions

View File

@ -2491,24 +2491,11 @@ static switch_status_t read_rtp_packet(switch_rtp_t *rtp_session, switch_size_t
}
rtp_session->stats.inbound.packet_count++;
}
if ((rtp_session->recv_te && rtp_session->recv_msg.header.pt == rtp_session->recv_te) ||
(*bytes < rtp_header_len && *bytes > 0) ||
switch_test_flag(rtp_session, SWITCH_RTP_FLAG_PROXY_MEDIA) || switch_test_flag(rtp_session, SWITCH_RTP_FLAG_UDPTL)) {
return SWITCH_STATUS_SUCCESS;
}
rtp_session->last_read_ts = ts;
if (!switch_test_flag(rtp_session, SWITCH_RTP_FLAG_PROXY_MEDIA) && !switch_test_flag(rtp_session, SWITCH_RTP_FLAG_UDPTL)) {
#ifdef ENABLE_ZRTP
/* ZRTP Recv */
if (*bytes) {
unsigned int sbytes = (int) *bytes;
zrtp_status_t stat = 0;
@ -2528,10 +2515,9 @@ static switch_status_t read_rtp_packet(switch_rtp_t *rtp_session, switch_size_t
default:
break;
}
}
#endif
if (*bytes && switch_test_flag(rtp_session, SWITCH_RTP_FLAG_SECURE_RECV)) {
if (switch_test_flag(rtp_session, SWITCH_RTP_FLAG_SECURE_RECV)) {
int sbytes = (int) *bytes;
err_status_t stat = 0;
@ -2569,6 +2555,17 @@ static switch_status_t read_rtp_packet(switch_rtp_t *rtp_session, switch_size_t
*bytes = sbytes;
}
}
}
if ((rtp_session->recv_te && rtp_session->recv_msg.header.pt == rtp_session->recv_te) ||
(*bytes < rtp_header_len && *bytes > 0) ||
switch_test_flag(rtp_session, SWITCH_RTP_FLAG_PROXY_MEDIA) || switch_test_flag(rtp_session, SWITCH_RTP_FLAG_UDPTL)) {
return SWITCH_STATUS_SUCCESS;
}
rtp_session->last_read_ts = ts;
if (switch_test_flag(rtp_session, SWITCH_RTP_FLAG_BYTESWAP) && rtp_session->recv_msg.header.pt == rtp_session->rpayload) {