Abdullah bin Umar reported,

We were with the Prophet ﷺ on a journey, and I was riding a young camel belonging to Umar that was difficult to control. It would get the better of me and push ahead of the group, so Umar would scold it and pull it back. Then it would push ahead again, and Umar would scold it and pull it back.The Prophet ﷺ said to Umar, "Sell it to me."Umar replied, "It is yours, Messenger of Allah."The Prophet ﷺ said again, "Sell it to me."So Umar sold it to the Messenger of Allah ﷺ, and the Prophet ﷺ said, "It is yours, Abdullah bin Umar. Do with it as you wish."

Bukhari 2115

Sahih

وقال لنا الحميدي حدثنا سفيان حدثنا عمرو

عن ابن عمر رضي الله عنهما قال

كنا مع النبي ﷺ في سفر فكنت على بكر صعب لعمر فكان يغلبني فيتقدم أمام القوم فيزجره عمر ويرده ثم يتقدم فيزجره عمر ويرده فقال النبي ﷺ لعمر بعنيه قال هو لك يا رسول الله قال بعنيه فباعه من رسول الله ﷺ فقال النبي ﷺ هو لك يا عبد الله بن عمر تصنع به ما شئت

البخاري 2115صحيح
Contents
Reference
Commentary
Ayat
Collection
Sahih Bukhari
Book
Sales
Chapter
If someone buys something and gives it as a gift immediately before they separate and the seller does not object to the buyer, or if he buys a slave and frees him
Numbering
Darussalam 2115
Bukhari 2115