mkfs.ubifs: use common ARRAY_SIZE
PATCH 1/1 mkfs.ubifs: use common ARRAY_SIZE
Signed-off-by Mike Frysinger <[email protected]>
--- mkfs.ubifs/hashtable/hashtable.c | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-)
mkfs.ubifs/hashtable/hashtable.c +2 -1
@@ -1,5 +1,6 @@/* Copyright (C) 2004 Christopher Clark <[email protected]> */ +#include "common.h" #include "hashtable.h" #include "hashtable_private.h" #include <stdlib.h>
@@ -21,7 +22,7 @@ static const unsigned int primes[] = {50331653 ,100663319 ,201326611 ,402653189 , 805306457, 1610612741 }; -const unsigned int prime_table_length =sizeof (primes)/sizeof (primes[0 ]); +const unsigned int prime_table_length =ARRAY_SIZE (primes);const float max_load_factor =0.65 ;/*****************************************************************************/
Signature · 1 line
1.7.3
Quoted 4 lines · Mike Frysinger
Signed-off-by Mike Frysinger <[email protected]>--- mkfs.ubifs/hashtable/hashtable.c | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-)
Pushed, thanks.
Signature · 2 lines
Best Regards, Artem Bityutskiy (Артём Битюцкий)