Whenever it shall appear to any court that a witness or party who has been sworn or examined in any case, matter, or proceeding pending before the court, has testified in such manner as to induce a reasonable presumption that he has wilfully and corruptly testified falsely to some material point or matter, the court may immediately commit such party or witness, by an order of process for that purpose, to prison, to take bond or recognizance with sureties for his appearing and answering to an indictment for perjury.