Util: Actually initialize the size of a table

This commit is contained in:
Jeffrey Pfau 2016-11-01 23:27:25 -07:00
parent dbdf10843e
commit 98a2e6e324
1 changed files with 1 additions and 0 deletions

View File

@ -70,6 +70,7 @@ void TableInit(struct Table* table, size_t initialSize, void (deinitializer(void
}
table->tableSize = initialSize;
table->table = calloc(table->tableSize, sizeof(struct TableList));
table->size = 0;
table->deinitializer = deinitializer;
size_t i;