Check NULL pointer dereference of the return value