(31) باب وَقْفِ الدَّوَابِّ وَالْكُرَاعِ وَالْعُرُوضِ وَالصَّامِتِ
Narrated Ibn `Umar:
Once `Umar gave a horse in charity to be used in holy fighting. It had been given to him by Allah's Apostle . `Umar gave it to another man to ride. Then `Umar was informed that the man put the horse for sale, so he asked Allah's Messenger (ﷺ) whether he could buy it. Allah's Messenger (ﷺ) replied, "You should not buy it, for you should not take back what you have given in charity."
Reference: Sahih al-Bukhari 2775
In-book reference: Book 55, Hadith 38
USC-MSA web (English) reference(deprecated numbering scheme): Vol. 4, Book 51, Hadith 36