It shall be the duty of such court during the term thereof to inquire into the cause of the commitment of every person confined in such prison upon any criminal charge who shall not have been indicted, or against whom no information shall have been filed, and unless satisfactory cause shall be shown to such court for detaining such person in custody or upon bail, as the case may require, to cause such person to be discharged.
MCL 801.23