Fix some null pointers.