actually initialize cache struct in got_object_cache_init()
diff --git a/lib/object_cache.c b/lib/object_cache.c
index 8957a46..7957b39 100644
--- a/lib/object_cache.c
+++ b/lib/object_cache.c
@@ -42,6 +42,8 @@ got_object_cache_init(struct got_object_cache *cache,
{
size_t size;
+ memset(cache, 0, sizeof(*cache));
+
switch (type) {
case GOT_OBJECT_CACHE_TYPE_OBJ:
size = GOT_OBJECT_CACHE_SIZE_OBJ;