Properly fix null dereference CID 18147