sh 53 gozilla/gozilla.c STRHASH *sh;
sh 114 gozilla/gozilla.c sh = strhash_open(10);
sh 154 gozilla/gozilla.c ent = strhash_assign(sh, name, 1);
sh 172 gozilla/gozilla.c struct sh_entry *ent = strhash_assign(sh, alias_name, 0);
sh 861 libutil/gtagsop.c struct sh_entry *sh;
sh 892 libutil/gtagsop.c sh = strhash_assign(gtop->path_hash, path, 1);
sh 893 libutil/gtagsop.c gtp->path = sh->name;
sh 86 libutil/strhash.c STRHASH *sh = (STRHASH *)check_calloc(sizeof(STRHASH), 1);
sh 89 libutil/strhash.c sh->htab = (struct sh_head *)check_calloc(sizeof(struct sh_head), buckets);
sh 91 libutil/strhash.c SLIST_INIT(&sh->htab[i]);
sh 92 libutil/strhash.c sh->buckets = buckets;
sh 93 libutil/strhash.c sh->pool = pool_open();
sh 94 libutil/strhash.c sh->entries = 0;
sh 95 libutil/strhash.c return sh;
sh 110 libutil/strhash.c strhash_assign(STRHASH *sh, const char *name, int force)
sh 112 libutil/strhash.c struct sh_head *head = &sh->htab[__hash_string(name) % sh->buckets];
sh 125 libutil/strhash.c entry = pool_malloc(sh->pool, sizeof(struct sh_entry));
sh 126 libutil/strhash.c entry->name = pool_strdup(sh->pool, name, 0);
sh 129 libutil/strhash.c sh->entries++;
sh 143 libutil/strhash.c strhash_strdup(STRHASH *sh, const char *string, int size)
sh 145 libutil/strhash.c return pool_strdup(sh->pool, string, size);
sh 153 libutil/strhash.c strhash_first(STRHASH *sh)
sh 155 libutil/strhash.c sh->cur_bucket = -1; /* to start from index 0. */
sh 156 libutil/strhash.c sh->cur_entry = NULL;
sh 157 libutil/strhash.c return strhash_next(sh);
sh 165 libutil/strhash.c strhash_next(STRHASH *sh)
sh 169 libutil/strhash.c if (sh->buckets > 0 && sh->cur_bucket < sh->buckets) {
sh 170 libutil/strhash.c entry = sh->cur_entry;
sh 172 libutil/strhash.c while (++sh->cur_bucket < sh->buckets) {
sh 173 libutil/strhash.c entry = SLIST_FIRST(&sh->htab[sh->cur_bucket]);
sh 178 libutil/strhash.c sh->cur_entry = (entry) ? SLIST_NEXT(entry, ptr) : NULL;
sh 188 libutil/strhash.c strhash_reset(STRHASH *sh)
sh 195 libutil/strhash.c for (i = 0; i < sh->buckets; i++) {
sh 196 libutil/strhash.c SLIST_INIT(&sh->htab[i]);
sh 201 libutil/strhash.c pool_reset(sh->pool);
sh 202 libutil/strhash.c sh->entries = 0;
sh 210 libutil/strhash.c strhash_close(STRHASH *sh)
sh 212 libutil/strhash.c pool_close(sh->pool);
sh 213 libutil/strhash.c free(sh->htab);
sh 214 libutil/strhash.c free(sh);