Hogs cannot be trusted. They are omnivorous and cannibalistic. A sow will eat her young if too many are born. Sometimes just because the sow was hungry and a piglet was close. We built the birthing stalls with the corners boarded with slots to give the piglets a refuge from the sow.
Boars are worse. They will eat you if given half a chance. We always went armed with a club of some kind. Dad usually carried a piece of 2X4 with a handle on one end that he'd carved. I carried a small baseball bat. If a hog looked as if they were thinking of make a snap at your leg, we'd give them a whack across the nose.