diff options
author | Michael Niedermayer <michael@niedermayer.cc> | 2019-08-06 10:35:38 +0200 |
---|---|---|
committer | Michael Niedermayer <michael@niedermayer.cc> | 2019-08-06 10:37:41 +0200 |
commit | 6c67c8ca9ae603b91e65274f93099ccb07bb33db (patch) | |
tree | ea08b6fc7ac74d3d48a8ab1b348eff714b19bd81 /libavformat/rtpdec_rfc4175.c | |
parent | 5ac28e9cc19069a104f5534dcf603218066d144c (diff) | |
download | ffmpeg-6c67c8ca9ae603b91e65274f93099ccb07bb33db.tar.gz |
Revert "avformat/rtpdec_rfc4175: Fix incorrect copy_offset calculation"
Reverted at the request of the Author due to potential regression with SMPTE 2110-20
This reverts commit 9051092e73666e95986eb2d596cc0867aea05c3d.
Diffstat (limited to 'libavformat/rtpdec_rfc4175.c')
-rw-r--r-- | libavformat/rtpdec_rfc4175.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/libavformat/rtpdec_rfc4175.c b/libavformat/rtpdec_rfc4175.c index 490db87520..e9c62c1389 100644 --- a/libavformat/rtpdec_rfc4175.c +++ b/libavformat/rtpdec_rfc4175.c @@ -205,11 +205,8 @@ static int rfc4175_handle_packet(AVFormatContext *ctx, PayloadContext *data, if (length > payload_len) length = payload_len; - if (line < 1) - return AVERROR_INVALIDDATA; - /* prevent ill-formed packets to write after buffer's end */ - copy_offset = ((line - 1) * data->width + offset) * data->pgroup / data->xinc; + copy_offset = (line * data->width + offset) * data->pgroup / data->xinc; if (copy_offset + length > data->frame_size) return AVERROR_INVALIDDATA; |