Fix null reference exception CID 18112