Sahih Muslim Book 10, Hadith Number 3792.
Chapter : Command of killing dogs and then its abrogation, and prohibition of keeping them but for hunting and protection of lands or cattle or like that.
Abu Mas’ud (Allah be pleased with him) reported Allah’s Messenger (may peace be upon him) as saying: A person from people who lived before you was called to account (by Allah at the Day of Judgment) and no good was found in his account except this that lie being a rich man had (financial) dealings with people and had commanded his servants to show leniency to the straitened ones. Upon this Allah, the Exalted and Majestic, said: We have more right to this, so overlook (his faults).