If a buyout happens, the trading freezes when a buyout happens, and it resumes at the price it was purchased for. You keep all your shares. just have the new price.