fix: fixed hash map get returns not being correct
parent
c4ec92fa82
commit
af50174b71
|
@ -25,7 +25,7 @@ void *hash_map_get_raw(HashMap *self, void *key) {
|
||||||
for(size_t i = 0; i < bucket.len; ++i) {
|
for(size_t i = 0; i < bucket.len; ++i) {
|
||||||
uintptr_t *key_at = list_at(&bucket, i);
|
uintptr_t *key_at = list_at(&bucket, i);
|
||||||
if(hash == *key_at)
|
if(hash == *key_at)
|
||||||
return ++key_at;
|
return ((char*)key_at) + sizeof(uintptr_t) + self->key_size;
|
||||||
}
|
}
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue