diff options
author | Kovarththanan Rajaratnam <kovarththanan.rajaratnam@gmail.com> | 2009-10-04 18:29:51 +0000 |
---|---|---|
committer | Kovarththanan Rajaratnam <kovarththanan.rajaratnam@gmail.com> | 2009-10-04 18:29:51 +0000 |
commit | 80f0d3116a3a449ae1c2862ead9848d3b4672745 (patch) | |
tree | e42e6e0a94b545b00e7464b027edfa59d1a07ea3 /plugins/wimax | |
parent | 09932ce535a5041d9f3c7f440bef1dfcb77a0000 (diff) |
Use G_N_ELEMENTS instead of hard coding size of array
svn path=/trunk/; revision=30315
Diffstat (limited to 'plugins/wimax')
-rw-r--r-- | plugins/wimax/crc.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/plugins/wimax/crc.c b/plugins/wimax/crc.c index 35a03a524b..63a73ddb9a 100644 --- a/plugins/wimax/crc.c +++ b/plugins/wimax/crc.c @@ -61,7 +61,7 @@ void wimax_mac_gen_crc32_table(void) guint32 crc; /* little-endian (reflected) algorithm */ - for ( index = 0; index < 256; index++ ) + for ( index = 0; index < G_N_ELEMENTS(crc32_table); index++ ) { crc = ( index << 24 ); for ( bit = 0; bit < 8; bit++ ) @@ -95,7 +95,7 @@ void wimax_mac_gen_crc8_table(void) guint index, bit; guint8 crc; - for ( index = 0; index < 256; index++ ) + for ( index = 0; index < G_N_ELEMENTS(crc8_table); index++ ) { crc = index; for ( bit = 0; bit < 8; bit++ ) |