diff vb.c @ 10972:3dd1cb77cc60 libavcodec

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.
author reimar
date Sat, 23 Jan 2010 15:22:48 +0000
parents d5f811c11f08
children 8a4984c5cacc
line wrap: on
line diff
--- a/vb.c	Sat Jan 23 15:19:34 2010 +0000
+++ b/vb.c	Sat Jan 23 15:22:48 2010 +0000
@@ -43,7 +43,7 @@
     AVFrame pic;
 
     uint8_t *frame, *prev_frame;
-    uint32_t pal[256];
+    uint32_t pal[AVPALETTE_COUNT];
     const uint8_t *stream;
 } VBDecContext;