diff options
Diffstat (limited to 'str_array.c')
-rw-r--r-- | str_array.c | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/str_array.c b/str_array.c index 1ff8348f..fb45f0a9 100644 --- a/str_array.c +++ b/str_array.c @@ -329,7 +329,7 @@ str_remove(NODE *symbol, NODE *subs) static NODE ** str_copy(NODE *symbol, NODE *newsymb) { - BUCKET **old, **new, **pnew; + BUCKET **old, **newtab, **pnew; BUCKET *chain, *newchain; unsigned long cursize, i; @@ -339,12 +339,12 @@ str_copy(NODE *symbol, NODE *newsymb) cursize = symbol->array_size; /* allocate new table */ - ezalloc(new, BUCKET **, cursize * sizeof(BUCKET *), "str_copy"); + ezalloc(newtab, BUCKET **, cursize * sizeof(BUCKET *), "str_copy"); old = symbol->buckets; for (i = 0; i < cursize; i++) { - for (chain = old[i], pnew = & new[i]; chain != NULL; + for (chain = old[i], pnew = & newtab[i]; chain != NULL; chain = chain->ahnext ) { NODE *oldval, *newsubs; @@ -380,7 +380,7 @@ str_copy(NODE *symbol, NODE *newsymb) } newsymb->table_size = symbol->table_size; - newsymb->buckets = new; + newsymb->buckets = newtab; newsymb->array_size = cursize; newsymb->flags = symbol->flags; return NULL; @@ -640,7 +640,7 @@ str_find(NODE *symbol, NODE *s1, size_t code1, unsigned long hash1) static void grow_table(NODE *symbol) { - BUCKET **old, **new; + BUCKET **old, **newtab; BUCKET *chain, *next; int i, j; unsigned long oldsize, newsize, k; @@ -679,10 +679,10 @@ grow_table(NODE *symbol) } /* allocate new table */ - ezalloc(new, BUCKET **, newsize * sizeof(BUCKET *), "grow_table"); + ezalloc(newtab, BUCKET **, newsize * sizeof(BUCKET *), "grow_table"); old = symbol->buckets; - symbol->buckets = new; + symbol->buckets = newtab; symbol->array_size = newsize; /* brand new hash table, set things up and return */ @@ -704,8 +704,8 @@ grow_table(NODE *symbol) hash1 = chain->ahcode % newsize; /* remove from old list, add to new */ - chain->ahnext = new[hash1]; - new[hash1] = chain; + chain->ahnext = newtab[hash1]; + newtab[hash1] = chain; } } efree(old); @@ -790,7 +790,7 @@ static unsigned long fnv1a_hash_string(const char *str, size_t len, unsigned long hsize, size_t *code) { /* FNV-1a */ - register unsigned ret = 2166136261U; + unsigned ret = 2166136261U; while (len > 0) { ret ^= (unsigned char) (*str++); |