am d3ceda68: Merge "Add in missing NULL pointer checks."

* commit 'd3ceda685bae5cdacfcc24866c625f4c28951a2a':
  Add in missing NULL pointer checks.