summaryrefslogtreecommitdiff
path: root/bfd
diff options
context:
space:
mode:
authorRoland McGrath <roland@gnu.org>2004-10-05 18:09:38 +0000
committerRoland McGrath <roland@gnu.org>2004-10-05 18:09:38 +0000
commitf1217d6d0570a8b3f7f2c8771cfd3e42055184f9 (patch)
tree1aacc7bc2794dc1436fa4562231b7ce814b61197 /bfd
parentc8425311a361c59fff0d99a06df5808b1e395703 (diff)
downloadgdb-f1217d6d0570a8b3f7f2c8771cfd3e42055184f9.tar.gz
2004-10-04 Roland McGrath <roland@redhat.com>
* hash.c (bfd_hash_set_default_size): Use const for table. Use size_t instead of int for variable compared to sizeof results.
Diffstat (limited to 'bfd')
-rw-r--r--bfd/hash.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/bfd/hash.c b/bfd/hash.c
index 2954ec8d12e..2b06b922ce3 100644
--- a/bfd/hash.c
+++ b/bfd/hash.c
@@ -504,12 +504,12 @@ bfd_hash_traverse (table, func, info)
void
bfd_hash_set_default_size (bfd_size_type hash_size)
{
- int index;
/* Extend this prime list if you want more granularity of hash table size. */
- static bfd_size_type hash_size_primes[] =
+ static const bfd_size_type hash_size_primes[] =
{
1021, 4051, 8599, 16699
};
+ size_t index;
/* Work out best prime number near the hash_size. */
for (index = 0; index < ARRAY_SIZE (hash_size_primes) - 1; ++index)