A man passed by the Messenger of Allah while he was relieving himself, and the man greeted him with salam. The Messenger of Allah returned the greeting, then said, "When you see me in this state, do not greet me with salam, for if you do, I will not return the greeting."
أن رجلا مر برسول الله وهو يهريق الماء، فسلم عليه الرجل، فرد عليه رسول الله، ثم قال: إذا رأيتني هكذا فلا تسلم علي؛ فإنك إن تفعل لا أرد عليك السلام.
Bazzar (5984) and Ibn Jarud in Al-Muntaqa (37) both narrated it through the route of Saeed bin Salama, who said, our teacher Abu Bakr told us, meaning the son of Umar bin Abdul-Rahman bin Abdullah bin Umar bin Khattab, from Nafi, from Ibn Umar, who said such and such.Regarding this Abu Bakr, Abdull-Haq Ishbili said, "As far as I know, he is the son of Umar bin Abdul-Rahman bin Abdullah bin Umar. Malik and others narrated from him, and there is nothing wrong with him." He then said, "But the hadith of Muslim is more sahih, because it comes through the hadith of Dahhak bin Uthman, from Nafi, from Ibn Umar, and Dahhak is more reliable than Abu Bakr. Perhaps this occurred on two separate occasions." End of quote. See Al-Ahkam al-Wusta (1/131).I say, this is stated explicitly in Musnad Sarraj (21), where he said, Muhammad bin Idris told us, Abdullah bin Raja told us, Saeed bin Salama told us, Abu Bakr bin Umar bin Abdul-Rahman bin Abdullah bin Umar bin Khattab told me, from Nafi, with the same wording. Zaylai also mentioned it.Its chain is hasan because of Saeed bin Salama, who is the son of Abu Husam Adawi, their freedman. Opinions about him differ. Nasai declared him daif, while others considered him acceptable. He has one hadith in Sahih Muslim, the hadith of Umm Zaraa, which Bukhari cited as corroborating evidence, and for which he narrated only a single hadith.The two hadiths can be reconciled by saying that he returned the greeting once and did not return it another time, and in both cases he knew that one should not do such a thing. So if he did do it, he would not repeat the greeting after that.