Mercurial > libavcodec.hg
comparison flicvideo.c @ 2422:18b8b2dcc037 libavcodec
various security fixes and precautionary checks
author | michael |
---|---|
date | Wed, 12 Jan 2005 00:16:25 +0000 |
parents | 39ad6cd5d4a6 |
children | faa53103dde0 |
comparison
equal
deleted
inserted
replaced
2421:e326490f58c4 | 2422:18b8b2dcc037 |
---|---|
174 color_changes = 256; | 174 color_changes = 256; |
175 | 175 |
176 for (j = 0; j < color_changes; j++) { | 176 for (j = 0; j < color_changes; j++) { |
177 | 177 |
178 /* wrap around, for good measure */ | 178 /* wrap around, for good measure */ |
179 if (palette_ptr >= 256) | 179 if ((unsigned)palette_ptr >= 256) |
180 palette_ptr = 0; | 180 palette_ptr = 0; |
181 | 181 |
182 r = buf[stream_ptr++] << color_shift; | 182 r = buf[stream_ptr++] << color_shift; |
183 g = buf[stream_ptr++] << color_shift; | 183 g = buf[stream_ptr++] << color_shift; |
184 b = buf[stream_ptr++] << color_shift; | 184 b = buf[stream_ptr++] << color_shift; |