summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohnny Richard <johnny@johnnyrichard.com>2022-04-19 03:06:22 +0200
committerJohnny Richard <johnny@johnnyrichard.com>2022-04-19 03:06:22 +0200
commitad4313dbe5987ad75d255aaa20c1a8e29f7cbda3 (patch)
treed61533798f9272e4f13dae573ceb8a7a10dfa787
parent4fe9748ba3c918cd8ef3319d00cebfccd9545bd2 (diff)
hash_table: Fix free casting warning
-rw-r--r--hash_table.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/hash_table.c b/hash_table.c
index 36fbe86..fe1ed85 100644
--- a/hash_table.c
+++ b/hash_table.c
@@ -114,7 +114,7 @@ hash_table_remove(hash_table_t *ht,
while (ht->entries[index].key != NULL) {
if (strcmp(key, ht->entries[index].key) == 0) {
- free(ht->entries[index].key);
+ free((void*) ht->entries[index].key);
ht->entries[index] = (hash_table_entry_t) { NULL, NULL };
ht->length--;
return true;