But in the use of C, malloc out space, its content is unknown, including on the stack space, if you don't initialize, its content is also unknown, is not 0, how do you explain, please book?
CodePudding user response:
Is under Linux system? Under Linux system should be 0CodePudding user response:
Also said the book, on page 588, malloc don't initialize it returns the memory, the need to have dynamic memory initialization of an application can use calloc, it will be allocated memory initialized to 0, binary zeros sacrifice cover page is the first time in CPU references when virtual page in such an area,