I always think simply if(p != NULL){..} will do the job. But after reading this Stack Overflow question, it seems not.
if(p != NULL){..}
So what\'s the canonical way to c
Apparently the thread you refer is about C++.
C++
In C your snippet will always work. I like the simpler if (p) { /* ... */ }.
C
if (p) { /* ... */ }