diff options
author | Aurelien Jacobs <aurel@gnuage.org> | 2008-10-21 21:40:24 +0000 |
---|---|---|
committer | Aurelien Jacobs <aurel@gnuage.org> | 2008-10-21 21:40:24 +0000 |
commit | 37d3e0667abd01124d783f3ca10a4aef05746a2a (patch) | |
tree | 284c171f9546a8f4dc4c12878ecb1c8333f63a76 /libavutil | |
parent | 03092e14089e086065bf05671260347ad94a6262 (diff) | |
download | ffmpeg-37d3e0667abd01124d783f3ca10a4aef05746a2a.tar.gz |
uses FF_ARRAY_ELEMS() where appropriate
Originally committed as revision 15662 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavutil')
-rw-r--r-- | libavutil/base64.c | 2 | ||||
-rw-r--r-- | libavutil/crc.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/libavutil/base64.c b/libavutil/base64.c index a6b44fb71c..97a77468f4 100644 --- a/libavutil/base64.c +++ b/libavutil/base64.c @@ -51,7 +51,7 @@ int av_base64_decode(uint8_t * out, const char *in, int out_length) v = 0; for (i = 0; in[i] && in[i] != '='; i++) { unsigned int index= in[i]-43; - if (index>=(sizeof(map2)/sizeof(map2[0])) || map2[index] == 0xff) + if (index>=FF_ARRAY_ELEMS(map2) || map2[index] == 0xff) return -1; v = (v << 6) + map2[index]; if (i & 3) { diff --git a/libavutil/crc.c b/libavutil/crc.c index 743a64038f..bc21f5bee8 100644 --- a/libavutil/crc.c +++ b/libavutil/crc.c @@ -91,7 +91,7 @@ int av_crc_init(AVCRC *ctx, int le, int bits, uint32_t poly, int ctx_size){ */ const AVCRC *av_crc_get_table(AVCRCId crc_id){ #ifndef CONFIG_HARDCODED_TABLES - if (!av_crc_table[crc_id][sizeof(av_crc_table[crc_id])/sizeof(av_crc_table[crc_id][0])-1]) + if (!av_crc_table[crc_id][FF_ARRAY_ELEMS(av_crc_table[crc_id])-1]) if (av_crc_init(av_crc_table[crc_id], av_crc_table_params[crc_id].le, av_crc_table_params[crc_id].bits, |