Old, turbines were hooked directly to the net, so the generator would be synced to the line frequency, that was what would synchronize the turbines and keep them from over speeding.
Modern windmills contain two switch mode converters:
The first converter takes the energy from the generator and charges a capacitor bank to the highest possible voltage.
The second converter takes the energy from the capacitor bank and dumps it into the net, at the right phase and frequency and at the highest possible current.
If the network is disconnected for some reason, then the second converter is unable to discharge the capacitor and the voltage will rise (for a very short time, milliseconds) and the first converter will be unable to keep the load on the generator and the windmill will start to over speed.
Once an over speed situation starts (or anything else unplanned) the controller will hit the air brakes (typically hydraulic rams with a huge reservoir which are used to turn the wings out of the wind), this braking is so powerful that the entire tower bends violently, both back-to-front because the load goes off the wings and the tower snaps back upright and from the torque introduced from mechanical and electrical braking.