Skip to content
Snippets Groups Projects
Commit 6560e618 authored by Michael Niedermayer's avatar Michael Niedermayer
Browse files

avformat/rmdec: Check codec_data_size


Fixes infinite loop
Fixes Ticket4154

Signed-off-by: default avatarMichael Niedermayer <michaelni@gmx.at>
(cherry picked from commit a6f73073)

Signed-off-by: default avatarMichael Niedermayer <michaelni@gmx.at>
parent 71b3f649
No related branches found
No related tags found
No related merge requests found
...@@ -309,6 +309,9 @@ ff_rm_read_mdpr_codecdata (AVFormatContext *s, AVIOContext *pb, ...@@ -309,6 +309,9 @@ ff_rm_read_mdpr_codecdata (AVFormatContext *s, AVIOContext *pb,
int64_t codec_pos; int64_t codec_pos;
int ret; int ret;
if (codec_data_size < 0)
return AVERROR_INVALIDDATA;
avpriv_set_pts_info(st, 64, 1, 1000); avpriv_set_pts_info(st, 64, 1, 1000);
codec_pos = avio_tell(pb); codec_pos = avio_tell(pb);
v = avio_rb32(pb); v = avio_rb32(pb);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment