crash fix and resume fix