We have already discussed and presented to readers quote from shia sheikh ibn Babaweyh regarding error of prophet (sallalahu alaihi wa ala alihi wa sallam) in the prayer.
Now, I’d like to present another quote from Majlisi, regarding the same question.
In his book, he said:
And Ibn Babuya and some muhadditheen say that sahw wa nusyan is not permissible (jaiz) for them (i.e the Prophets) but it is permissible (jaiz) that Allah make them sahw due to some reasons. As the Prophet (as) did sahw in the prayer of Asr or Dhuhr, and said ‘salam’ in the first tash’had. When the people reminded him, he prayed the remaining two rakat. They say that it was for the reason that if someone amongst the ummah does sahw, the others don’t criticize him and secondly that (the people) don’t start assuming them to be gods. But the other scholars don’t accept this sahw and consider the ahadith in this regard to be due to taqiyah.
Haqqul Yaqin, Vol. 1, p. 25
Explaining this by taqiyyah, is most ridiculous thing that I have ever heard.
PS. Translated by brother Kalaam.