git.videolan.org
/
ffmpeg.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
3f0b6d7
)
wavpack: check packet size early
author
Luca Barbato
<lu_zero@gentoo.org>
Wed, 22 May 2013 10:51:42 +0000
(12:51 +0200)
committer
Luca Barbato
<lu_zero@gentoo.org>
Wed, 22 May 2013 20:02:57 +0000
(22:02 +0200)
Reported-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
CC: libav-stable@libav.org
libavcodec/wavpack.c
patch
|
blob
|
history
diff --git
a/libavcodec/wavpack.c
b/libavcodec/wavpack.c
index
cfcd22d
..
e6e9872
100644
(file)
--- a/
libavcodec/wavpack.c
+++ b/
libavcodec/wavpack.c
@@
-1203,6
+1203,9
@@
static int wavpack_decode_frame(AVCodecContext *avctx, void *data,
int frame_size, ret, frame_flags;
int samplecount = 0;
+ if (avpkt->size < 12 + s->multichannel * 4)
+ return AVERROR_INVALIDDATA;
+
s->block = 0;
s->ch_offset = 0;