
I of course have my own hypotheses, but I wanted the opinions of my lovely friends here. See what you think.
So I have this dog. Beria is her name; she's my baby. She's not the brightest dog, and she's not always the best-behaved dog, but I take her as is. :3

Normally, she's alright around people. A little shy, but alright. She hates little kids, though, and will snap at them when I'm not around her. By little, I mean toddler age.
Now, she's NOT a great dog around my neighbor Kevin. I love the kid; I call him my adopted little brother. Great boy. A little annoying at times, but what kid isn't? He's thirteen or so, and he and his brother and sister came over to my house to hang out.
He startled Beria a little earlier in the day, and walked up to her really suddenly. She got frightened, and snapped her jaws at him a few times, but it was far from connecting with any skin.
I warned Kevin that he'd startled her, and she didn't like that. He understood, of course, and I apologized for her acting a little overboard like that.
Later on, we're playing a board game in the living room. Beria was laying on the floor by the couch, happy as you please. She'd let Kevin and his siblings pet her earlier, acting like the nicest dog you'd ever seen.
All of a sudden, when she got up and was walking past Kevin, who was just sitting there counting his play money, she freaked out and started trying to bite him. She caught him (and myself, who was too far away to restrain her) by surprise, and got him pretty nicely in the lower back. I got over there as quickly as I could and put her outside on her chain after scolding her, obviously. She didn't puncture the skin, but there was a nice-looking bruise forming on his back. He was a little startled, as could be expected, but assured me that he was fine. I kept her outside for the remainder of the time they stayed.
Kevin has never, to my knowledge, done anything to Beria that would evoke such behavior. Nor is he young enough to fall into her realm of disliked 'children.' And sometimes, she'll be very nice around him, let him pet her and wag her tail, all that mumbo jumbo. And then once in a while, things like this happen. She's never actually BITTEN him before today; just snapping. I can't quite put my finger on what causes it. He didn't do anything to startle her, that time, or make her feel on the defensive. She had a clear route through, no block-ins, but she just stopped and nailed him.
Understandably, he doesn't like to be around her now, so there aren't any little bonding sessions that I can initialize to make her more comfortable around him. I'm just not sure what started the problem.