| 253 | } |
| 254 | |
| 255 | static dictEntry *dictFind(dict *ht, const void *key) { |
| 256 | dictEntry *he; |
| 257 | unsigned int h; |
| 258 | |
| 259 | if (ht->size == 0) return NULL; |
| 260 | h = dictHashKey(ht, key) & ht->sizemask; |
| 261 | he = ht->table[h]; |
| 262 | while(he) { |
| 263 | if (dictCompareHashKeys(ht, key, he->key)) |
| 264 | return he; |
| 265 | he = he->next; |
| 266 | } |
| 267 | return NULL; |
| 268 | } |
| 269 | |
| 270 | static dictIterator *dictGetIterator(dict *ht) { |
| 271 | dictIterator *iter = hi_malloc(sizeof(*iter)); |
no outgoing calls
no test coverage detected