Muwatta Malik, Book 41, Hadith 1513 (In-Book)

Malik related to me that he had heard that Uthman ibn Affan was brought a woman who had given birth after six months and he ordered her to be stoned. Ali ibn Abi Talib said to him, "She does not deserve that. Allah, the Blessed, the Exalted, says in His Book, 'Their carrying and weaning is thirty months,' (Sura 46 ayat 15) and he said, 'Mothers suckle their children for two full years for whoever wishes to complete the suckling.' (Sura 2 ayat 233) Pregnancy can then be six months, so she does not deserve to be stoned." Uthman ibn Affan sent for her and found that she had already been stoned. Malik related to me that he asked Ibn Shihab about someone who committed sodomy. Ibn Shihab said, "He is to be stoned, whether or not he is muhsan."

وَحَدَّثَنِي مَالِكٌ، أَنَّهُ بَلَغَهُ أَنَّ عُثْمَانَ بْنَ عَفَّانَ، أُتِيَ بِامْرَأَةٍ قَدْ وَلَدَتْ فِي سِتَّةِ أَشْهُرٍ فَأَمَرَ بِهَا أَنْ تُرْجَمَ فَقَالَ عَلِيُّ بْنُ أَبِي طَالِبٍ لَيْسَ ذَلِكَ عَلَيْهَا إِنَّ اللَّهَ تَبَارَكَ وَتَعَالَى يَقُولُ فِي كِتَابِهِ ‏{‏وَحَمْلُهُ وَفِصَالُهُ ثَلاَثُونَ شَهْرًا‏}‏ وَقَالَ ‏{‏وَالْوَالِدَاتُ يُرْضِعْنَ أَوْلاَدَهُنَّ حَوْلَيْنِ كَامِلَيْنِ لِمَنْ أَرَادَ أَنْ يُتِمَّ الرَّضَاعَةَ‏}‏ فَالْحَمْلُ يَكُونُ سِتَّةَ أَشْهُرٍ فَلاَ رَجْمَ عَلَيْهَا ‏.‏ فَبَعَثَ عُثْمَانُ بْنُ عَفَّانَ فِي أَثَرِهَا فَوَجَدَهَا قَدْ رُجِمَتْ ‏.‏

sunnah.com

also referenced under: Book 41, Hadith 11 (USC-MSA)