Sahih al-Bukhari, Hadith 1316

Narrated Abu Sa`id Al-Khudri: The Prophet said, "When a funeral is ready and the men carry the deceased on their necks (shoulders), if it was pious then it will say, 'Present me quickly', and if it was not pious, then it will say, 'Woe to it (me), where are they taking it (me)?' And its voice is heard by everything except mankind and if he heard it he would fall unconscious."

حَدَّثَنَا عَبْدُ اللَّهِ بْنُ يُوسُفَ، حَدَّثَنَا اللَّيْثُ، حَدَّثَنَا سَعِيدٌ، عَنْ أَبِيهِ، أَنَّهُ سَمِعَ أَبَا سَعِيدٍ الْخُدْرِيَّ ـ رضى الله عنه ـ قَالَ كَانَ النَّبِيُّ صلى الله عليه وسلم يَقُولُ ‏ "‏ إِذَا وُضِعَتِ الْجِنَازَةُ فَاحْتَمَلَهَا الرِّجَالُ عَلَى أَعْنَاقِهِمْ، فَإِنْ كَانَتْ صَالِحَةً قَالَتْ قَدِّمُونِي‏.‏ وَإِنْ كَانَتْ غَيْرَ صَالِحَةٍ قَالَتْ لأَهْلِهَا يَا وَيْلَهَا أَيْنَ يَذْهَبُونَ بِهَا يَسْمَعُ صَوْتَهَا كُلُّ شَىْءٍ إِلاَّ الإِنْسَانَ، وَلَوْ سَمِعَ الإِنْسَانُ لَصَعِقَ ‏" ‏‏.‏

sunnah.com