fix crash issue on UT