I don't recall any hadiths where Muslims killed children. Isn't that prohibited?
Paloma already answered this:
In fact, the ahadith literature contains statements which allow Muslims to murder older persons, women and children. Certain narrations claim that Muhammad permitted his soldiers to engage in night raids that would have exposed innocent women and children to physical harm:
Narrated As-Sab bin Jaththama:
The Prophet passed by me at a place called Al-Abwa or Waddan, and was asked whether it was permissible to attack the pagan warriors at night with the probability of exposing their women and children to danger. The Prophet replied, "They (i.e. women and children) are from them (i.e. pagans)." I also heard the Prophet saying, "The institution of Hima is invalid except for Allah and His Apostle." (Sahih Al-Bukhari, Volume 4, Book 52, Number 256)
Also, in the Banu Quraizai massacre any males who had hit puberty were killed, and hitting puberty does not make you an adult.