(a) Sayyiduna al-Mughirah bin Shu'bah (may Allah be pleased with him) says that the Messenger of Allah (peace and blessings be upon him) was delayed for the prayer. Then he mentioned the whole story. He says: We (the Prophet (peace and blessings be upon him) and I) came to the people while Sayyiduna Abd al-Rahman bin Awf (may Allah be pleased with him) was leading them in the morning prayer. When he saw the Prophet (peace and blessings be upon him), he wanted to step back, but he (peace and blessings be upon him) gestured to him: "Continue your prayer." Then the Prophet (peace and blessings be upon him) and I prayed one rak'ah behind Sayyiduna Abd al-Rahman bin Awf (may Allah be pleased with him). When he gave the salam, the Prophet (peace and blessings be upon him) stood up and prayed the rak'ah that he had missed, and did not add anything more to it (such as the prostration of forgetfulness).
(b) Imam Abu Dawud (may Allah have mercy on him) says: Sayyiduna Abu Sa'id al-Khudri, Sayyiduna Ibn Umar and Sayyiduna Ibn al-Zubayr (may Allah be pleased with them) say that whoever catches one rak'ah of the prayer must perform the prostration of forgetfulness.
(c) Imam al-Bayhaqi (may Allah have mercy on him) says that the hadith of the Messenger of Allah (peace and blessings be upon him) is more worthy of being followed.
Hadith Referenceالسنن الكبرى للبيهقي / كتاب الصلاة / 3888