Fix crashes.