ticket.61804: Fix illegal state exception crash