In the 18th and 19th centuries, masturbation was considered to be the source of a laundry list of pathologies, from insanity to hair loss. Onanism, or “spilling the seed” by ejaculating outside of intercourse intended for procreation, was a sin and medical danger.
If a patient had ejaculations outside of marital intercourse, or released more semen than is typical, then he was diagnosed with a disease called spermatorrhea or “seminal weakness.” A variety of drugs (including sedation) and other severe treatments, including circumcision and castration, were advised as treatment.
This is an image of a “German Spermatorrhoea Ring,” circa 1894. Boys were fitted with these rings, or other elaborate devices, to prevent nocturnal erections and masturbation. If the penis got erect, the sharp teeth would puncture the shaft of the penis, causing great pain and potential injury.
Women were not spared brutal medical treatment for masturbation: cauterization of the clitoris was common medical practice.
Happily, the medical field has come a long way in the past century and doctors now heartily recommend regular masturbation for both male and female sexual health. Cock rings can be left for folks to explore on a more voluntary and pleasurable basis.