I am curious as to what part of the dereferencing a NULL ptr causes undesired behavior. Example:
// #1
someObj * a;
a = NULL;
(*a).somefunc(); // crash, dere
Dereferencing a NULL pointer is undefined behavior.
It is not guaranteed to crash, and you are not guaranteed anything when doing it. For all you know someone somewhere in the world will be punched each time you do it. That is valid behavior since it is undefined.
Also your pointers may not be initialized to NULL so if you want them to be for sure NULL you should set them explicitly to NULL.