Mishkat al-Masabih 1517
وَعَنِ ابْنِ عَبَّاسٍ أَنَّ رَجُلًا لَعَنَ الرِّيحَ عِنْدَ النَّبِيِّ صَلَّى اللَّهُ عَلَيْهِ وَسَلَّمَ فَقَالَ: «لَا تَلْعَنُوا الرِّيحَ فَإِنَّهَا مَأْمُورَةٌ وَأَنَّهُ مَنْ لَعَنَ شَيْئًا لَيْسَ لَهُ بِأَهْلٍ رَجَعَتِ اللَّعْنَةُ عَلَيْهِ» . رَوَاهُ التِّرْمِذِيُّ وَقَالَ: هَذَا حَدِيثٌ غَرِيبٌ
From Ibn ʿAbbas: A man cursed the wind in the presence of the Prophet ﷺ, and he said: "Do not curse the wind, for it is under command; and whoever curses something that does not deserve it, the curse returns upon him." Reported by at-Tirmidhi, and he said: "This is a gharib hadith."