Accidently reverted a commit that fixed a crash.