It was narrated from Ibn Buhainah that the Prophet صلی اللہ علیہ وآلہ وسلم prayed, then he stood up after two Rak’ahs while he was supposed to sit, and he continued his prayer. Then at the end of his prayer, he performed two prostrations before the Salam, then he said the Salam. (Sahih).