Hopefully fixed a few rare crashes