summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlex Converse <alex.converse@gmail.com>2009-02-03 22:59:47 +0000
committerAlex Converse <alex.converse@gmail.com>2009-02-03 22:59:47 +0000
commit2c823b3ccca3a9d42d02713fc5ea2538a9b9a99e (patch)
tree8a5eca0874e4eb3bb53e9cc374ebeb6e17fa950a
parent20e2a7aed283c55205724f5226eb854c5a5498bd (diff)
VP3: Prevent stack corruption from an unset custom coding method.
Originally committed as revision 16978 to svn://svn.ffmpeg.org/ffmpeg/trunk
-rw-r--r--libavcodec/vp3.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/libavcodec/vp3.c b/libavcodec/vp3.c
index 8dc2da4f03..c44e6e49b7 100644
--- a/libavcodec/vp3.c
+++ b/libavcodec/vp3.c
@@ -742,6 +742,8 @@ static int unpack_modes(Vp3DecodeContext *s, GetBitContext *gb)
/* is it a custom coding scheme? */
if (scheme == 0) {
for (i = 0; i < 8; i++)
+ custom_mode_alphabet[i] = MODE_INTER_NO_MV;
+ for (i = 0; i < 8; i++)
custom_mode_alphabet[get_bits(gb, 3)] = i;
}