Get a charley horse

To develop a cramp in the arm or the leg.

The swimmer got a charley horse while he was swimming.