Abu Dawud Book 24, Hadith Number 3919.

Chapter : Sale of a slave who entered an agreement to purchase his freedom when the agreement is repudiated.

Narated By N/A : ‘Aisha said : Barirah came seeking my help to purchase her freedom. She said: I have arranged with my people to buy my freedom for nine uqiyahs : one to be paid annually. So help me. She (‘Aisha) said: If your people are willing that I should count them (uqiyahs) Out to them all at one time and set you free and that I shall have the right to inherit from you, I shall do so. She then went to her people. The narrator then transmitted the rest of the tradition like the version of al-Zuhri. He added to the wordings of the Prophet (may peace be upon him) in the last: What is the matter with people that one of you says: Set free, O so-and-so, and the right of inheritance belongs to me. The right of inheritance belongs only to the one who has set a person free.