In tractate Makot page 5 the Gemara says that the regular laws about witnesses that have been refuted applies even in in cases that require lashes. [So the false witnesses do not get makot unless the sentence was already decided. That is the case was settled to give lashes to the innocent person and after that other witnesses came and to those witnesses "How could have seen that felony in such and such a place when you were with us in another place that whole day?"
This is a question on the Rambam that writes if an innocent person was given lashes because of their false testimony, they get lashes. This is a question because the general law about false witnesses is that they get the punishment they wanted to give only if they tried to give it but not of it was actually preformed.
The Minhat Hinuch, Rav Akiva Eiger, and the Pnei Yehoshua all answer that the Rambam holds they get lashes because of the verse לא תענה ברעך עד שקר thou shalt not testify false witness against thy neighbor.
But that does not answer the fact that the gemara says to receive any punishment for false testimony one needs the regular laws of false witnesses -that includes "as they planned, not as they did." שאשר זמם ולא כאשר עשה
Rav Shach brings an different answer to try to explain the Rambam from the book "HaMeir LaOlam" that we say אין עונשים מן הדין [We do not give a punishment because of a "all the more so"] only in the case of a death penalty. [The idea of that answer is that normally you would say if witnesses wanted to give a punishment and they turn out to we liars then they get that same punishment then all the more so if they actually succeeded in getting that innocent person to get the punishment. But we do not say that in the case of a death penalty because the is a special traditional teaching] "as they planned, not as they did." שאשר זמם ולא כאשר עשה.
However Rav Shach shows from the Tosefta that this answer does not hold because the Tosefta holds that [We do not give a punishment because of a "all the more so"] even applies to all other areas like laws about money. However Tospfot [in the very beginning Bava Kama]does hold that there is an argument between our Mishna and the Tosefta about this very issue.
Rav Haim of Brisk has a different answer for the Rambam. He says that lashes is different from the death penalty or a monetary fine. lashes needs to be done in a legal court and if not it is just hitting. So even if the false witnesses did get the penalty to be applied to the innocent person, that still is is in the category of "they planned to do but did not do." Rav Shach however asks on this for they never plan on giving a legal penalty to an innocent person. In any penalty they know they are lying. They simply want either to have the person get the death penalty or lashes of whatever. And if they succeeded then they succeeded. So in all cases it is a case they would not get that penalty. So in conclusion there does not seem to be any answer for the Rambam.