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
commit90cdf78ff463cdb7aaa927ba83b7d555a0e1dbe4 (patch)
treeadfb9e7beedddf1d38f649a367591c7508bc7a63 /bfd/bfd-in.h
parent047594149d533062514bc8f8c6ab6304a35185a2 (diff)
downloadbinutils-redhat-90cdf78ff463cdb7aaa927ba83b7d555a0e1dbe4.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 e671ee7d23..35ce396529 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. */