Sunan an-Nasa'i, Book 21, Hadith 37 (In-Book)

It was narrated that 'Imran bin Husain said: "The deceased is punished due to his family's wailing for him." A man said to him: "A man died in Khurasan and his family wailed for him here; will he be punished due to his family's wailing?" He said: "The Messenger of Allah spoke the truth and you are a liar."

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

sunnah.com