MFC: r208776
Avoid possible NULL-dereferences.
Found with: Coverity Prevent(tm) CID: 3428 Approved by: re (kib)