prevent crash