History

rtpdec: Fix the minimum packet length for RTCP SR packets

We actually read 20 bytes of these packets.

John Brooks committed 15 years ago

Commit 5d6ecf51 parent c6825141 file · +1 −1Browse files

Unified · Split

libavformat/rtpdec.c+1−1
@@ -115,7 +115,7 @@ static int rtcp_parse_packet(RTPDemuxContext *s, const unsigned char *buf, int l · 114 unmodified lines
115115 while (len >= 2) {
116116 switch (buf[1]) {
117117 case RTCP_SR:
118− if (len < 16) {
118+ if (len < 20) {
119119 av_log(NULL, AV_LOG_ERROR, "Invalid length for RTCP SR packet\n");
120120 return AVERROR_INVALIDDATA;
121121 }

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t