A man from Aslam came to the Prophet ﷺ and confessed to fornication. The Prophet ﷺ turned away from him until he had testified against himself four times.The Prophet ﷺ asked him, "Are you insane?"He replied, "No."The Prophet ﷺ asked, "Are you married?"He replied, "Yes."So the Prophet ﷺ ordered that he be stoned at the prayer ground. When the stones struck him painfully, he fled, but he was caught and stoned until he died. The Prophet ﷺ spoke well of him, but did not perform the funeral prayer over him.
أن رجلا من أسلم جاء النبي ﷺ فاعترف بالزنا، فأعرض عنه النبي ﷺ حتى شهد على نفسه أربع مرات، قال له النبي ﷺ: أبك جنون؟ قال: لا، قال: أحصنت؟ قال: نعم، قال: فأمر النبي ﷺ فرجم بالمصلى، فلما أذلقته الحجارة فر، فأدرك فرجم حتى مات، فقال النبي ﷺ خيرا، ولم يصل عليه.
Bukhari narrated it in the Book of Legal Punishments (6820), and Muslim in the Book of Legal Punishments (16/1691), both from the hadith of Abdul-Razzaq, and it is in his Musannaf (13337), from Mamar, from Zuhri, from Abu Salama bin Abdul-Rahman, from Jabir, who related the hadith. The wording given here is from the Musannaf of Abdul-Razzaq. As for Muslim, he did not give the full wording, and as for Bukhari, he said, "and he prayed over him," which is an error, as Bayhaqi (8/218) stated, for everyone who narrated it through the route of Abdul-Razzaq did not say in it "and he prayed over him." Among them are Abu Dawud (4430), Tirmidhi (1429), Nasai (1956), Ahmad (14462), and others.Then Bukhari said, "Yunus and Ibn Jurayj, from Zuhri, did not say 'so he prayed over him.'" I say, likewise Mamar, from Zuhri, did not say "so he prayed over him," rather he said "and he did not pray over him," as mentioned previously.As for what Abu Barza Aslami narrated, that the Messenger of Allah ﷺ did not pray over Maiz bin Malik, and did not forbid praying over him, it contains unknown men. Abu Dawud narrated it (3186) from Abu Kamil, who said, Abu Awana narrated to us, from Abu Bishr, who said, a group of the people of Basra narrated to me, from Abu Barza Aslami, who related it. The group of the people of Basra are men who are unknown.