Fixed freeze/unfreeze crash