Can someone please explain why pointers aren't initialized to NULL?
Example:
void test(){
char *buf;
if (!buf)
// whatever
}
The program wouldn't step inside the if because buf is not null.
I would like to know why, in what case do we need a variable with trash on, specially pointers addressing the trash on the memory?