diff options
author | Diego Biurrun <diego@biurrun.de> | 2011-06-06 14:13:02 +0200 |
---|---|---|
committer | Diego Biurrun <diego@biurrun.de> | 2012-03-28 09:38:33 +0200 |
commit | a92be9b856bd11b081041c43c25d442028fe9a63 (patch) | |
tree | 32f852fdf904a30238c789e57510be710eaa7826 /libavcodec/4xm.c | |
parent | 856c8e0a049dc7069b7504d3aaa48549c75852de (diff) | |
download | ffmpeg-a92be9b856bd11b081041c43c25d442028fe9a63.tar.gz |
Replace memset(0) by zero initializations.
Also remove one pointless zero initialization in rangecoder.c.
Diffstat (limited to 'libavcodec/4xm.c')
-rw-r--r-- | libavcodec/4xm.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/libavcodec/4xm.c b/libavcodec/4xm.c index 139a642a47..8cc5592c73 100644 --- a/libavcodec/4xm.c +++ b/libavcodec/4xm.c @@ -552,7 +552,7 @@ static int decode_i_mb(FourXContext *f) static const uint8_t *read_huffman_tables(FourXContext *f, const uint8_t * const buf) { - int frequency[512]; + int frequency[512] = { 0 }; uint8_t flag[512]; int up[512]; uint8_t len_tab[257]; @@ -561,7 +561,6 @@ static const uint8_t *read_huffman_tables(FourXContext *f, const uint8_t *ptr = buf; int j; - memset(frequency, 0, sizeof(frequency)); memset(up, -1, sizeof(up)); start = *ptr++; @@ -661,8 +660,7 @@ static int decode_i2_frame(FourXContext *f, const uint8_t *buf, int length) for (y = 0; y < height; y += 16) { for (x = 0; x < width; x += 16) { - unsigned int color[4], bits; - memset(color, 0, sizeof(color)); + unsigned int color[4] = { 0 }, bits; // warning following is purely guessed ... color[0] = bytestream2_get_le16u(&g3); color[1] = bytestream2_get_le16u(&g3); |