Fix possible null pointer dereference.

Fixes CID 966176