Almost all professional employment in the US is characterized as at-will. How can someone get ensure their work agreement accounts for this prior to starting a job at one of these companies? Ask for a "you will not fire me prior to paying me a bonus" clause?
It seems to me that if a company in this situation wants to screw the employee, they will find a way.