Sahih Muslim Book 4, Hadith Number 2026.

Chapter : The dead body is punished for the lamentation of his family.

Hisham b. ‘Urwa narrated on the authority of his father that the saying of Ibn ‘Umar, viz. “The dead would be punished because of the lamentation of his family over him” was mentioned to ‘Aisha. Upon this she said: May Allah have mercy upon Abu ‘Abd al-Rahman (the kunya of Ibn ‘Umar) that he heard something but could not retain it (well). (The fact is) that the bier of a Jew passed before the Messenger of Allah (may peace be upon him) and (the members of his family) were waiting over him. Upon this he said: You are wailing and he is being punished.