Try to prevent the crash in the spell selection gui. Untested.