Fix coverity defects:  Explicit null dereferenced (FORWARD_NULL)