summaryrefslogtreecommitdiff
path: root/bfd/bfd-in.h
diff options
context:
space:
mode:
authorAlan Modra <amodra@bigpond.net.au>2006-11-20 01:38:38 +0000
committerAlan Modra <amodra@bigpond.net.au>2006-11-20 01:38:38 +0000
commite67d01d8a631ddf16b590e0c13074401311a8e2f (patch)
treefbda61a7e5f25731d833a649f2109ff5741bad76 /bfd/bfd-in.h
parent8b0ad437a22556993e17f4ccee2cda1665ba56e2 (diff)
downloadgdb-e67d01d8a631ddf16b590e0c13074401311a8e2f.tar.gz
PR 3532
* bfd-in.h (struct bfd_hash_table): Reorganize. Add "frozen". * hash.c (bfd_hash_table_init_n): Init frozen. (bfd_hash_lookup): Don't grow if frozen. (bfd_hash_traverse): Freeze hash table during traversal. * bfd-in2.h: Regenerate.
Diffstat (limited to 'bfd/bfd-in.h')
-rw-r--r--bfd/bfd-in.h14
1 files changed, 8 insertions, 6 deletions
diff --git a/bfd/bfd-in.h b/bfd/bfd-in.h
index e671ee7d23e..35ce3965292 100644
--- a/bfd/bfd-in.h
+++ b/bfd/bfd-in.h
@@ -398,12 +398,6 @@ struct bfd_hash_table
{
/* The hash array. */
struct bfd_hash_entry **table;
- /* The number of slots in the hash table. */
- unsigned int size;
- /* The number of entries in the hash table. */
- unsigned int count;
- /* The size of elements. */
- unsigned int entsize;
/* A function used to create new elements in the hash table. The
first entry is itself a pointer to an element. When this
function is first invoked, this pointer will be NULL. However,
@@ -416,6 +410,14 @@ struct bfd_hash_table
/* An objalloc for this hash table. This is a struct objalloc *,
but we use void * to avoid requiring the inclusion of objalloc.h. */
void *memory;
+ /* The number of slots in the hash table. */
+ unsigned int size;
+ /* The number of entries in the hash table. */
+ unsigned int count;
+ /* The size of elements. */
+ unsigned int entsize;
+ /* If non-zero, don't grow the hash table. */
+ unsigned int frozen:1;
};
/* Initialize a hash table. */