Sahih Muslim Book 22, Hadith Number 4862.

Chapter : It was not permissible to eat the flesh of sacrificial animals beyond three days at the beginning of Islam, but this prohibition was abrogated, and now it is permissible.

Salama b. al-Akwa’ reported Allah’s Messenger (way peace be upon him) having said: He who sacrifices (animal) among you nothing should be left in his house (out of its flesh) on the morning of the third day. When it was the next year they (his Companions) said: Should we do this year as we did daring the previous year? Thereupon he said: Don’t do that, for that was a year when the people were hard pressed (on account of poverty), so I wanted that the (flesh) might be distributed amongst them.