diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2014-01-01 15:29:20 +0100 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2014-01-01 16:53:54 +0100 |
commit | 06bb1de1c78a3653e197ff3434d550499b556e72 (patch) | |
tree | 2a588e64bb79b95db44890ac5a33c4fb552477b5 /libavformat/vqf.c | |
parent | e6364ea26df9b39023f6986200dc1731b7bdf2d3 (diff) | |
download | ffmpeg-06bb1de1c78a3653e197ff3434d550499b556e72.tar.gz |
avformat/vqf: check avio_read()s return value more completely
Fixes use of uninitialized memory
Fixes: msan_uninit-mem_7f180a523a71_5052_esvorbei_extd.vqf
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavformat/vqf.c')
-rw-r--r-- | libavformat/vqf.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavformat/vqf.c b/libavformat/vqf.c index 526b596146..74c7f5fc17 100644 --- a/libavformat/vqf.c +++ b/libavformat/vqf.c @@ -249,7 +249,7 @@ static int vqf_read_packet(AVFormatContext *s, AVPacket *pkt) pkt->data[1] = c->last_frame_bits; ret = avio_read(s->pb, pkt->data+2, size); - if (ret<=0) { + if (ret != size) { av_free_packet(pkt); return AVERROR(EIO); } |