A similar situation happened to our family when I was a kid. We were given an adult Dalmatian since previous family wanted to throw it away, mother said she'd take it off their hands. One afternoon my previous neighbor's cousin came over to drop something off and started to pet the dog. Her downfall came when she started to pet the scuff of the neck, an area which makes dogs hostile (as it's instinct to aim for the neck when dogs intend to hurt).
She didn't know that and that's when it happened. The dog bit her arm and had to be taken to the hospital. An eight inch scar later and several talks with animal control (the dog was registered and vaccinated), they decided that it was best to put our dog down. The kicker? He was minding his own business. She was the one who went over to try to pet him.
Moral of the story: I didn't think then that our dog had to be put down because of the girl's ignorance and I don't believe this one should either. Never get near an animal if you're not familiar with it and always let the owner know if you're going to get close. Harsh as it sounds - both girls didn't listen/ask for permission so let them learn the hard way.