Hadithcore
Mishkat al-Masabih, 1572

Abu Sa'id reported God’s messenger as saying, "When you go in to visit an invalid, express a hope that he will live long. That will not avert anything, but it will comfort him.” Tirmidhl and Ibn Majah transmitted it, and Tirmidhi said this is a <i>gharib</i> tradition.

وَعَنْ أَبِي سَعِيدٍ قَالَ: قَالَ رَسُولُ اللَّهِ صَلَّى اللَّهُ عَلَيْهِ وَسَلَّمَ: «إِذَا دَخَلْتُمْ عَلَى الْمَرِيضِ فَنَفِّسُوا لَهُ فِي أَجَلِهِ فَإِنَّ ذَلِكَ لَا يَرُدُّ شَيْئًا وَيُطَيِّبُ بِنَفْسِهِ» . رَوَاهُ التِّرْمِذِيُّ وَابْنُ مَاجَهْ وَقَالَ التِّرْمِذِيُّ: هَذَا حَدِيثٌ غَرِيبٌ

References1 variant
In-Book Reference
Book 5, Hadith 50