diff --git a/ionc/ion_allocation.c b/ionc/ion_allocation.c index af10781..f28db06 100644 --- a/ionc/ion_allocation.c +++ b/ionc/ion_allocation.c @@ -179,7 +179,7 @@ ION_ALLOCATION_CHAIN *_ion_alloc_block(SIZE min_needed) SIZE alloc_size = min_needed + ALIGN_SIZE(sizeof(ION_ALLOCATION_CHAIN)); // subtract out the block[1] new_block = (ION_ALLOCATION_CHAIN *)ion_xalloc(alloc_size); - memset(new_block, 0, sizeof(*new_block)); + memset(new_block, 0, alloc_size); new_block->size = alloc_size; // see if we suceeded