Sunan an-Nasa'i, Book 22, Hadith 172 (Nasa'i 2266)

It was narrated from a man, from Jabir that the Messenger of Allah said:

"It is not righteousness to fast when traveling."