Sahih Bukhari
Fasting
Volume: 003 / Book Number: 031 / Hadith Number: 167
Narrated Jabir bin 'Abdullah:
Allah's Apostle was on a journey and saw a crowd of people, and a man was being shaded (by them). He asked, "What is the matter?" They said, "He (the man) is fasting." The Prophet said, "It is not righteousness that you fast on a journey."