summaryrefslogtreecommitdiff
path: root/libavcodec/vb.c
diff options
context:
space:
mode:
authorReimar Döffinger <Reimar.Doeffinger@gmx.de>2010-01-23 15:22:48 +0000
committerReimar Döffinger <Reimar.Doeffinger@gmx.de>2010-01-23 15:22:48 +0000
commit87ac0c0a39268654c8a6ae4b3acb7a01f9d942bb (patch)
tree2e10fcf30d13a174ca98a0a4006c149102a26d95 /libavcodec/vb.c
parentab8075a2dac453e4bb720184ad9841d24f7055a4 (diff)
Use AVPALETTE_COUNT instead of hard-coding 256.
This is consistent with other codecs and will also avoid a crash on the memcpy to data[1] if AVPALETTE_SIZE ever increases. Originally committed as revision 21399 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/vb.c')
-rw-r--r--libavcodec/vb.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/vb.c b/libavcodec/vb.c
index 155ccebbc4..4dfac435ac 100644
--- a/libavcodec/vb.c
+++ b/libavcodec/vb.c
@@ -43,7 +43,7 @@ typedef struct VBDecContext {
AVFrame pic;
uint8_t *frame, *prev_frame;
- uint32_t pal[256];
+ uint32_t pal[AVPALETTE_COUNT];
const uint8_t *stream;
} VBDecContext;