Altered code to zero out the memory that we create.