aboutsummaryrefslogtreecommitdiff
path: root/bfd/bfd-in.h
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2006-11-20 01:38:38 +0000
committerAlan Modra <amodra@gmail.com>2006-11-20 01:38:38 +0000
commit98f0b6ab8c1d2e1528a93e9e483f8d666243a67d (patch)
tree2f7079344fc8f631cbc8a938fb53005f2b916cab /bfd/bfd-in.h
parent98a16ee117073d28a8c6863e9c8d7e2575bc1736 (diff)
downloadgdb-98f0b6ab8c1d2e1528a93e9e483f8d666243a67d.zip
gdb-98f0b6ab8c1d2e1528a93e9e483f8d666243a67d.tar.gz
gdb-98f0b6ab8c1d2e1528a93e9e483f8d666243a67d.tar.bz2
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 e671ee7..35ce396 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. */