fixed crash bug for release