Sayyiduna Jabir reports that an Ansari man declared his slave as Mudabbar (i.e., said: "After my death, you are free"), so the Messenger of Allah (peace and blessings be upon him) sold him.
Hadith Referenceالمنتقى ابن الجارود / كتاب الطلاق / 983
Hadith Gradingغلام مصطفےٰ ظهير امن پوري:صحيح
Hadith Takhrijاز غلام مصطفےٰ ظهير امن پوري:«صحيح البخاري : 2534، صحيح مسلم : 997۔»