7e2c4ebca145638ee16f713004f8fb521ebeae51 angie Fri Feb 7 13:07:22 2014 -0800 Fixing a couple comments that promise too much. diff --git src/lib/hash.c src/lib/hash.c index b6ab3a0..770647f 100644 --- src/lib/hash.c +++ src/lib/hash.c @@ -400,47 +400,44 @@ } } /* restore original list order */ for (i=0; isize; ++i) { struct hashEl *hel = hash->table[i]; if (hel != NULL && hel->next != NULL) slReverse(&hash->table[i]); } freeMem(oldTable); hash->numResizes++; } struct hash *hashFromSlNameList(void *list) -/* Create a hash out of a list of slNames or any kind of list where the */ -/* first field is the next pointer and the second is the name. */ +/* Create a hash out of a list of slNames. */ { struct hash *hash = NULL; struct slName *namedList = list, *item; if (!list) return NULL; hash = newHash(0); for (item = namedList; item != NULL; item = item->next) hashAdd(hash, item->name, item); return hash; } struct hash *hashSetFromSlNameList(void *list) -/* Create a hashSet (hash with only keys) out of a list of slNames or any kind - * of list where the first field is the next pointer and the second is the name. - * Returns NULL if the list is NULL. */ +/* Create a hashSet (hash with only keys) out of a list of slNames. */ { struct hash *hash = NULL; struct slName *namedList = list, *item; if (!list) return NULL; hash = newHash(0); for (item = namedList; item != NULL; item = item->next) hashAdd(hash, item->name, NULL); return hash; } void hashTraverseEls(struct hash *hash, void (*func)(struct hashEl *hel)) /* Apply func to every element of hash with hashEl as parameter. */ { int i;