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

It wasnarrated that Ibn ‘Abbas said: “A man died at the time of theMessenger of Allah (PBUH), and he left no heir except for a slave whomhe had set free. The Messenger of Allah (PBUH) gave the legacy tohim.” Translation Not Available

Book Ref: Sunan Ibn Majah Book 23 Hadith 2741
Web Ref:  Sunan Ibn Majah Vol 4 Book 23 Hadith 2741