Sunan Ibn Majah, Volume 3, Book 15, Hadith 2395 (DarusSalam)

It was narrated from 'Amr bin Shu'aib, from his father, that his grandfather said: “A man came to the Prophet and said: 'I gave my mother a garden of mine, and she has died and has no other heir but me.' The Messenger of Allah said: 'Your charity is valid and your garden has been returned to you.' ”

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

sunnah.com