[FFmpeg-cvslog] r21399 - trunk/libavcodec/vb.c

reimar subversion
Sat Jan 23 16:22:48 CET 2010


Author: reimar
Date: Sat Jan 23 16:22:48 2010
New Revision: 21399

Log:
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.

Modified:
   trunk/libavcodec/vb.c

Modified: trunk/libavcodec/vb.c
==============================================================================
--- trunk/libavcodec/vb.c	Sat Jan 23 16:19:34 2010	(r21398)
+++ trunk/libavcodec/vb.c	Sat Jan 23 16:22:48 2010	(r21399)
@@ -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;
 



More information about the ffmpeg-cvslog mailing list