Sunan At-Tirmidhi

Hadith #408

Abdullah bin Amr narrated that:Allah's Messenger (S) said: ""When he commits Hadath - meaning a man - and he is sitting in the end of his Salat before saying the Taslim, then his Salat is acceptable