there is a wide variety of similar treatments for farm animals that are entirely for the animals well being
pigs get their tail curled and tusks removed as babies so they dont accidentally nip each other while playing or stab each other just walking around- even a small tail nip might be fatal once the other pigs react to the scent of blood
goats/cows often have their horns removed as babies as well both for obvious reasons to prevent stabbings but also to prevent them from growing in weird that can cause pain and infection for the animal
chickens and other poultry, especially pet ones or hobby farms, might have their flight feathers clipped to prevent them from flying over fences, where their life expectancy is nill outside the farm/owners enclosure