when you malloc() some memory, all it does is search for some free space in memory, and tracking is now used. He does not initialize it or anything else.
when you call free() , all it does is free this block of memory from the list of used memory blocks. Again, it does not change the contents.
source share