[Asterisk-code-review] res rtp asterisk: Drop rtcp packets less than 2 words in le... (asterisk[15])
George Joseph
asteriskteam at digium.com
Wed Sep 6 15:30:14 CDT 2017
George Joseph has uploaded this change for review. ( https://gerrit.asterisk.org/6445
Change subject: res_rtp_asterisk: Drop rtcp packets less than 2 words in length
......................................................................
res_rtp_asterisk: Drop rtcp packets less than 2 words in length
Don't bother checking anything else.
Change-Id: I67d89e3c27db83efa0e6b52734f73c88ac2939e2
---
M res/res_rtp_asterisk.c
1 file changed, 5 insertions(+), 0 deletions(-)
git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/45/6445/1
diff --git a/res/res_rtp_asterisk.c b/res/res_rtp_asterisk.c
index 091533e..6fb2b90 100644
--- a/res/res_rtp_asterisk.c
+++ b/res/res_rtp_asterisk.c
@@ -4785,6 +4785,11 @@
ast_debug(1, "Got RTCP report of %zu bytes\n", size);
+ if (packetwords < 2) {
+ ast_debug(1, "RTCP frame size (%d words) is shorter than 2 words\n", packetwords);
+ return f;
+ }
+
while (position < packetwords) {
int i, pt, rc;
unsigned int length;
--
To view, visit https://gerrit.asterisk.org/6445
To unsubscribe, visit https://gerrit.asterisk.org/settings
Gerrit-Project: asterisk
Gerrit-Branch: 15
Gerrit-MessageType: newchange
Gerrit-Change-Id: I67d89e3c27db83efa0e6b52734f73c88ac2939e2
Gerrit-Change-Number: 6445
Gerrit-PatchSet: 1
Gerrit-Owner: George Joseph <gjoseph at digium.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20170906/89c1fc8b/attachment-0001.html>
More information about the asterisk-code-review
mailing list