Same. I've read up on this plenty before embarking on animal breeding. I built a farm, trying to make it as natural looking as possible, winding path fences with animal and tree fields either side, instead of square flat boxes everywhere. I'm not too bothered about bears or wolves, since I kill all I find, and I'm constantly expanding the farm, so it'll eventually get a 4 high wall around it with mechanised gate. Unless I'm mistaken, and anyone here can point to bears and wolves respawning in the area inside land you think is safe, not the wild.
Someone mentioned in a comment I read, that putting wooden paths down either side of fences prevents snow from building up, so animals won't be able to climb out. I've done that and it works great, and 2 generations in to my pig breeding I had no escapes, ......until my third winter, when I've now found 4 gen 2 sows, and 2 gen 3 piglets roaming round my oak tree field, and just now a gen 3 boar in my redwood field, both of which border the back of the pig pen.
It must be chunks not loading as LadyWYT says, same problem that Minecraft encounters. I guess that means I'm going to have to move the pig pen when the snow thaws out. Build a number of much smaller pigsties that are self contained within each chunk. Then if only 1 or two load it doesn't matter, there's no gap in the wall. That is really annoying though, it kills any immersion and role play.
(Edit)
Just for a pointer, does anyone know if it makes any difference if you use rough hewn fences or proper fences? I doubt it, but it's worth asking anyway.