From 5de46227348289590a6eae24f804938753af00f5 Mon Sep 17 00:00:00 2001 From: Seven Du Date: Thu, 7 Jan 2016 17:00:48 +0800 Subject: [PATCH] Revert "FS-8713 #resolve avoid read exceeding buffer" This reverts commit 1746d2ebc026e54aac35304b8885f385bb1067da. --- src/switch_jitterbuffer.c | 2 -- src/switch_rtp.c | 2 +- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/src/switch_jitterbuffer.c b/src/switch_jitterbuffer.c index 1bfc63fce2..3d096c764d 100644 --- a/src/switch_jitterbuffer.c +++ b/src/switch_jitterbuffer.c @@ -1088,8 +1088,6 @@ SWITCH_DECLARE(switch_status_t) switch_jb_put_packet(switch_jb_t *jb, switch_rtp uint32_t i; uint16_t want = ntohs(jb->next_seq), got = ntohs(packet->header.seq); - switch_assert(len <= SWITCH_RTP_MAX_BUF_LEN); - switch_mutex_lock(jb->mutex); if (!want) want = got; diff --git a/src/switch_rtp.c b/src/switch_rtp.c index d88de1e89e..5646b8e86e 100644 --- a/src/switch_rtp.c +++ b/src/switch_rtp.c @@ -5132,7 +5132,7 @@ static switch_status_t read_rtp_packet(switch_rtp_t *rtp_session, switch_size_t block = 0; } - *bytes = SWITCH_RTP_MAX_BUF_LEN; + *bytes = sizeof(rtp_msg_t); sync = 0; rtp_session->has_rtp = 0;