Check for a NULL pointer dereference.

--HG--
extra : rebase_source : 91c95190c0e39e48e79c1479e2c63bf096976867