More questions can also be asked.
Was the dog tormented by other people? Perhaps by his owners? Did the dog every fight with any other dogs in the area? did the dog ever bite any one else? Does the dog get daily walks? is the dog allowed to socialize? was the dog fed that day? watered that day?
Because this is learned behavior. There may be a history of neglect and fighting. Also if the dog is not allowed to socialize on a normal basis.. this can cause negative behavior throughout their lives.
Honestly, I completely agree with you, which is why I said that I dont really blame the dog but it doesnt change the fact that the dog still has the mentality to attack children unprovoked which is why I think it should be put down (unless a better alternative can be found).