# HG changeset patch # User reimar # Date 1264260168 0 # Node ID 3dd1cb77cc602be4bcd54ac573de8f8a5df02246 # Parent d5f811c11f0813151f5a8b7bb89debfa3827d5b2 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. diff -r d5f811c11f08 -r 3dd1cb77cc60 vb.c --- 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;