وَعَنْ جَابِرٍ
أَنَّ رَجُلًا زَنَى بِامْرَأَةٍ فَأَمَرَ بِهِ النَّبِيُّ صَلَّى اللَّهُ عَلَيْهِ وَسَلَّمَ فَجُلِدَ الْحَدَّ ثُمَّ أُخْبِرَ أَنَّهُ مُحْصَنٌ فَأَمَرَ بِهِ فرجم
A man committed fornication with a woman and the Prophet (sallallahu alayhi wa sallam) gave command that he be given the appropriate beating, but on being told afterwards that the man was married he gave command that he should be stoned to death.