from Abu Hurayrah, not a hadith from Anas ibn Malik from the Prophet, peace and blessings be upon him. Perhaps there is an omission in Ibn Shadhan’s collection.
This is supported by what I found in my rough notes: Ibn Shadhan narrated in “the eighth of his sections” (15/1), from al-Hasan, from Anas ibn Hakim, from Abu Hurayrah, the same hadith. Sufyan ibn Husayn likewise narrated it from Ali ibn Zayd, from Anas ibn Hakim al-Dabbi, who said: Abu Hurayrah said to me, “When you come to the people of your town, tell them that I heard the Messenger of Allah, peace and blessings be upon him, say...” He then cited a similar wording, which includes:
“If his prayer is sound, then it is sound; otherwise, it is supplemented from his voluntary prayers. Then the rest of the obligatory deeds will be dealt with in the same manner.”
Ahmad (2/290), Ibn Nasr, and al-Baghawi in Sharh al-Sunnah (2/24/1) recorded it. Al-Baghawi said: “A good hadith.”
I say: It is as he said, for this Anas ibn Hakim is a narrator of unascertained standing, as stated in al-Taqrib. Ibn Judan also narrated from him, and Ibn Hibban listed him in al-Thiqat (3/14). Yunus ibn Ubayd corroborated him, narrating from al-Hasan, from Anas ibn Hakim al-Dabbi, from Abu Hurayrah, with a more complete version of it. Ahmad (2/425) and Ibn Nasr recorded it.
Humayd also corroborated it, narrating from al-Hasan, from Abu Hurayrah, omitting Anas ibn Hakim between them. Perhaps al-Hasan concealed him by omitting him in this narration. Ahmad (4/103) recorded it.
Al-Hasan had another teacher for this hadith: Hammam ibn Yahya narrated it from Qatadah, from al-Hasan, from Hurayth ibn Qabisah, who said: “I came to Madinah and met Abu Hurayrah ... He said: ‘I heard the Messenger of Allah, peace and blessings be upon him...’” He then cited it, like the earlier narration of Aban ibn Yazid al-Attar. Al-Nasa’i (1/81), al-Tirmidhi (2/270), who graded it good, Ibn Nasr, and al-Tahawi in al-Mushkil (3/227) recorded it. Al-Tahawi and Ibn Shadhan, in “the eighth of his sections” (14/2), then recorded it by two routes from al-Hasan, from—in one of them, “he informed me”—Sasa‘ah, from Abu Hurayrah.