It was narrated from Ibn`Umar that the Messenger of Allah (ﷺ) said:
"Whoever frees a slave who has some wealth, the slave's wealth belongs to him, unless the master stipulates that it will belong to him." (JA)
English reference (JA): Vol. 3, Book 19, Hadith 2529 (JA)
Arabic reference (JA): Book 19, Hadith 2625 (JA)