If the founder retains a controlling interest in the business (say 51% stock ownership) are they safe from these shenanigans?
Philosophically, even if not written in the contract, someone could convince you to dilute at the last minute. The best interest of a buyer is to put the target in close bankruptcy before buying it. Anything is possible in peer-to-peer negotiations, and legal framework can only go so far.