use zmalloc, which asserts memory has been allocated and initializes it to 0