It is narrated from Sayyiduna Jabir (may Allah be pleased with him) that once the Prophet (peace and blessings be upon him) was on a journey. On the way, he saw that people had gathered around a man and were shading him. Upon inquiry, the people said that he was fasting. The Prophet (peace and blessings be upon him) said: "Fasting while on a journey is not an act of righteousness."