At the risk of being labeled a Master of the Obvious, castration would prevent any recurrence of that behavior!
Not necessarily. Castration only amputates testicles.