Zirr (may Allah have mercy on him) narrates: I came to Sayyiduna Safwan bin Assal (may Allah be pleased with him), and he said: "When we travelled with the Messenger of Allah (peace and blessings be upon him), he (peace and blessings be upon him) would order us not to take off our leather socks for three nights and their days except for major ritual impurity (janabah); as for defecation or urination, (we would) not (take them off) because of them."
Hadith Referenceالمعجم الكبير للطبراني / باب الصاد / 7323