I'm just wondering about what happens to memory that a user program releases through a brk system call, then gets back again. Does the kernel clear it out or is the contents left undefined?
I believe that the kernel clears out pages when they are newly allocated via brk, but I can't work out if it zeros them all if that page is returned, then requested back again. I'm looking through lxr.linux.no to try to find out. I'll also have a look at the book suggested in this post.
Thanks for your replies.
Tim