From 30b9a6cc88f7f89fa0b3795e422936e4f3048e85 Mon Sep 17 00:00:00 2001 From: tidwall Date: Sun, 21 Mar 2021 07:55:03 -0700 Subject: [PATCH] Fix cast needed for MSVC fixes #9 --- hashmap.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hashmap.c b/hashmap.c index b171292..5d217f2 100644 --- a/hashmap.c +++ b/hashmap.c @@ -118,7 +118,7 @@ struct hashmap *hashmap_new(size_t elsize, size_t cap, map->compare = compare; map->udata = udata; map->spare = ((char*)map)+sizeof(struct hashmap); - map->edata = map->spare+bucketsz; + map->edata = (char*)map->spare+bucketsz; map->cap = cap; map->nbuckets = cap; map->mask = map->nbuckets-1;