Mozilla crash workaround

Closes #540