Section 15-21-2
Persons entitled to prosecute writ - Persons confined for failure to enter into undertaking to keep the peace.
Any person confined in jail for failing to enter into an undertaking to keep the peace may prosecute a writ of habeas corpus as provided in this chapter; but such writ can be heard only by a judge of the circuit court, who may discharge the applicant, remand him to jail or reduce the amount of the undertaking as may seem right. If the amount of the undertaking is reduced, the sheriff must discharge the applicant upon the entering into the undertaking in the sum fixed by such judge.
(Code 1896, §4813; Code 1907, §7008; Code 1923, §4306; Code 1940, T. 15, §2.)