Sunan an-Nasa'i, Book 21, Hadith 133 (Nasa'i 1955)

It was narrated that Abu Hurairah said:

"The Messenger of Allah was asked about the children of the idolators and he said: 'Allah knows best what they would have done."'