Sayyiduna Abdullah bin Umar (may Allah be pleased with them) narrates that the Prophet Muhammad (peace and blessings be upon him) was urinating, a man passed by and greeted him with salam, but the Prophet (peace and blessings be upon him) did not reply.
Hadith Referenceالمنتقى ابن الجارود / كتاب الطهارة / 38
Hadith Gradingغلام مصطفےٰ ظهير امن پوري: صحيح مسلم