From 34fe50818d9cfb7c6200875985f12546e9400f22 Mon Sep 17 00:00:00 2001 From: Joshua Haberman Date: Tue, 7 Jul 2009 01:08:00 -0700 Subject: Removed minimum table size, reduces memory footprint. --- upb_table.c | 1 - 1 file changed, 1 deletion(-) diff --git a/upb_table.c b/upb_table.c index bad0b23..03fab2f 100644 --- a/upb_table.c +++ b/upb_table.c @@ -29,7 +29,6 @@ void upb_table_init(struct upb_table *t, uint32_t size, uint16_t entry_size) t->entry_size = entry_size; t->size_lg2 = 1; while(size >>= 1) t->size_lg2++; - t->size_lg2 = max(t->size_lg2, 4); /* Min size of 16. */ size_t bytes = upb_table_size(t) * t->entry_size; t->entries = malloc(bytes); memset(t->entries, 0, bytes); /* Both tables consider 0's an empty entry. */ -- cgit v1.2.3