Mishkat al-Masabih 4554
‘Abdallah b. ‘Umar told that he heard God’s messenger say:
“If I drink an antidote, or tie on an amulet, or compose poetry, I am the type who does not care what he does.”*

Abu Dawud transmitted it.

* Meaning that one who does any such thing is an abandoned character.
وَعَنْ عَبْدِ اللَّهِ بْنِ عُمَرَ قَالَ: سَمِعْتُ رَسُولَ اللَّهِ صَلَّى اللَّهُ عَلَيْهِ وَسَلَّمَ يَقُولُ: «مَا أُبَالِي مَا أَتَيْتُ إِنْ أَنَا شَرِبْتُ تِرْيَاقًا أَوْ تَعَلَّقْتُ تَمِيمَةً أَوْ قُلْتُ الشِّعْرَ مِنْ قِبَلِ نَفْسِي» . رَوَاهُ أَبُو دَاوُد