[No. 1721.]

#### Ex Parte S. TANI.

1. Criminal Law— Sentence — Erroneous in Part — Effect. On conviction of a felony, the sentence imposed was within the discretion vested in the district court as to the amount of the fine and the time of alternative imprisonment in the event that the fine was not paid, and was erroneo'us only in that it declared that such alternative imprisonment should be in the state prison, whereas, under the express provisions of Comp. Laws, 2667, it should have declared that the same should be in the county jail. *HeM,*that, in *habeas corpus*proceedings, such direction as to the place of imprisonment might be rejected as surplusage, and did not vitiate the entire sentence.

APPLICATION by S. Tani for a writ of *habeas corpus*against the Warden of the State Prison.

Denied, and the warden of the state prison directed to deliver petitioner to the sheriff of Washoe County, Nevada, to be by him detained in the county'jail for the remainder of the term of imprisonment imposed by his sentence, unless the part of the fine remaining unsatisfied be sooner paid.

The facts sufficiently appear in the opinion.

*Benj. Curler,*for Petitioner:

I. We contend in this case that the court exceeded its jurisdiction in imprisoning the petitioner in the state prison *386for five hundred days, and that there is no provision of law authorizing the court to imprison the petitioner in the state prison, for five hundred days, or any other number of days. The court had, under Comp. Laws, 4701, jurisdiction to impose a fine upon the petitioner of one thousand dollars, but imprisonment for five hundred days is illegal and void. Comp. Laws, 2267, is as follows: "Whenever any prisoner, under conviction for any criminal offense, shall be confined in jail for any inability to pay any fine, forfeiture, or costs, or to procure sureties, the district court, upon satisfactory evidence of such inability, may, in lieu thereof, confine such person in the county jail, at the rate of two dollars per day, until the fine, forfeiture, or costs so imposed shall have been satisfied." Under this section the court certainly received satisfactory evidence, after the writ of execution had been returned and satisfied, that the petitioner was unable to pay his fine, and the most that he could do would be to confine the petitioner in the county jail at the rate of two dollars per day until the fine was satisfied. If the judgment of the court is not warranted and authorized by law, or that portion of it, which confines him in the penitentiary, exceeds the jurisdiction of the court, then the relator’s imprisonment is illegal, and he has a right to be discharged on the writ of *habeas corpus. {People*v. *Liscomb,*60 N. Y. 559, and authorities cited.) When a person is held under a judgment of a court made without authority of law, the proper tribunal, will, upon *habeas corpus,*look into the records so far as to ascertain this fact; and if it be found to be so, will discharge the prisoner. *{Ex parte Lange,*18 Wall. 163.) The judgment of the court in confining the relator in the state prison is void, 'because in excess of that which by law the court had power to make. *{Bigelow*v. *Eorrest,*9 Wall. 339.) On application for a writ of *habeas corpus*the judgment under which the prisoner is held is a unit, and if one portion of it is without the jurisdiction of the court which made it, the whole is void. *{Ex parte Kelly,*65 Cal. 154; *Ex parte Bernert,*62 Cal. 524.)

II. Where an offender is sentenced for a longer term of imprisonment than is prescribed for the particular offense, *387or where he is condemned to pay a ñne and be imprisoned for an offense which is punishable by fine or imprisonment, or where the sentence is severable and a part of it is of the nature prescribed by law and the other part is not, as where an offender is sentenced to imprisonment in the penitentiary and to pay a fine, when the punishment authorized .by law for the particular offense is a fine and imprisonment in the county jail, the authorities hold that an excessive sentence is invalid *in toto,*and a discharge on *habeas corpus*has been granted on that ground. (15 Am. & Eng. Eney. Law, 2d ed. 172; *Px parte Page,*49 Mo. 291.) The above case was decided under a statute providing that when a prisoner is brought up on *habeas corpus,*if it appears that he is in custody by virtue of process of any court or judicial officer, he can be discharged only in one of the following cases: First — Where the jurisdiction of such court or officer has been exceeded, either as to matter, place, sum, or person. * * * Sixth— Where the process is not authorized by any judgment, order, or decree, nor by any provision of law. (See, also, *Px parte Mooney,*26 W. Va. 36; *Px parte Gox,*32 Pac. 197.)

*Ii,. G. Stoddard,*Attorney - General, for Respondent:

I. The court had jurisdiction to impose said fine, and in default of the satisfaction thereof to order that defendant "be imprisoned in the state prison of the State of Nevada, for the period of five hundred days, or for one day for each and every two dollars of the said fine not satisfied.” (Comp. Laws, 3988, 4413, 4418, 4646, 4701.)

II. Even if, as petitioner contends, he should have been sentenced to the county jail, he is not entitled to his release on *habeas corpus,*as the place of confinement is no part of the judgment, and, if the conviction is valid, he could be remanded to the custody of the trial court to be dealt with according to law. *(In re Harris,*35 Atl. 55; *People*v. *Kelly,*97 N. Y. 252; *Px parte Symons j*62 Ala. 416; *Koepe*v. *Hill,*87 Am. St. Rep. 192.)

By the Court,

Talbot, C. J.:

Defendant was indicted for the crime of assault with intent to kill. He entered a plea of guilty of assault with a deadly *388weapon with intent to inflict upon the person of another a bodily injury, where no considerable provocation appears, and the sentence of the court was that he be fined $1,000, and, in the event the fine be not paid, that he be imprisoned in the state prison for a period of 500 days, or one day for each and every $2 of the fine not satisfied. No payment being made he was committed to the custody of the warden of the state prison, and now asks to be released by writ of *habeas corpus,*asserting that the district court w'as without jurisdiction to confine him in that institution, and that therefore the sentence is void.

Section 4701 of the Compiled Laws of Nevada provides: "An assault with a deadly weapon, instrument, or other thing, with an intent to inflict upon the person of another a bodily injury, where no considerable provocation appears, or where the circumstances of the assault show an abandoned and malignant,' heart, shall subject the offender to imprisonment in- the state prison not less than one year, or exceeding two years, or to a fine not less than one thousand nor exceeding five thousand dollars, or to both such fine and imprisonment.” Section 3988: "A felony is a public offense punishable with death, or by imprisonment in the territorial prison.” Section 4413: "A judgment that the defendant pay a fine may' also direct that he be imprisoned until the fine be satisfied, specifying the extent of the imprisonment, which shall not exceed one day for every two dollars of the fine, or in that proportion.” Section 4418: "If the judgment be imprisonment, or a fine and imprisonment until it be satisfied, the defendant shall forthwith be committed to the custody of the proper officer, and by him detained until the judgment be complied with.”. Section 4646: "If the fine be not paid the court may order the defendant to be imprisoned one day for each two dollars of the fine not paid.” Section 2267: "Whenever any prisoner, under conviction for any criminal offense, shall be confined in jail for any inability to pay any fine, forfeiture, or costs, or to procure sureties, the district court, upon satisfactory evidence of such inability, may, in lieu thereof, confine such person in the county jail, at the rate of two dollars per day, until the fine, forfeiture, *389or cost so imposed shall have been satisfied.” Section 3761 provides that it shall be the duty of the judge hearing the writ of *habeas corpus,*"if the time during which such party may be legally detained in custody has not expired, to remand such party, if it shall appear that he is detained in custody by virtue of the final judgment or decree of any competent court of criminal jurisdiction, or of any process issued upon such judgment or decree, or in cases of contempt of court”; and section 3762 that: "If it appears on the return of the writ of *habeas corpus*that the prisoner is in custody by virtue of process from any court of this territory, or judge or officer thereof, such prisoner may be discharged, in any one of the following eases; subject to the restrictions of the last preceding section: First — When the jurisdiction of such court or officer has been exceeded. Second — When the imprisonment was at first lawful, yet by some act, omission, or event, which has taken place afterwards, the party has' become entitled to be discharged. Third — When the process is defective in some matter of substance required by law, rendering such process void. Fourth — When the process, though proper in form, has been issued in a case not allowed by law. Fifth — When the person having the custody of the prisoner is not the person allowed by law to detain him. Sixth — Where the process is not authorized by any judgment, order, or decree of any court, nor by any provision of law.”

On behalf of petitioner, it is urged that under section 2267 the district court was without jurisdiction to order the defendant imprisoned in any place other than the county jail, and that the direction in the judgment that he be confined in the state prison, in lieu of payment of the fine, was unauthorized and rendered the whole judgment void.

Of the cases relied upon by him the first four following support this contention:

In *Ex parte Page,*49 Mo. 291, the sentence of ten years for grand larceny was excessive, and it was held that the court had no power to reduce the term of imprisonment so as to bring it within the statutory limit, and the prisoner was discharged.

*390In *Ex parte Cox,*32 Pac. 197, 3 Idaho, 530, 95 Am. St. Rep. 29, an Idaho case, the defendant was convicted of an assault with a deadly weapon likely to produce great bodily harm, and sentenced to confinement in the state prison for the term of five years, when the statutory penalty was imprisonment not exceeding two years, or a fine of $5,000, or both. The judgment was declared void, and the petitioner released.

In *Ex parte Kelly,*65 Cal. 154, 3 Pac. 673, it was held that the portion of judgment requiring the performance of labor on the streets was not authorized, that the judgment was a unit, and that this portion of it, being without the jurisdiction of the court, made the whole void.

*Ex parte Bernert,*62 Cal. 524, is of similar effect.

But the views of the courts regarding the proposition involved are as numerous and varied as the different liquors from the magician's bottle. The most of the decisions, and especially those more in consonance with reason and justice, are averse to the discharge of criminals who have been duly convicted when the application for their release is by petition for *habeas corpus*based on some error, omission, or mistake in the sentence which might have been cured or corrected by writ of error or appeal. As we shall see, the Supreme Court of California has not always been consistent in its opinions, and the doctrine advanced by the foregoing eases has been severely criticised by the Supreme Courts of the United States, of Pennsylvania, and Massachusetts, and is contrary to the weight of authority.

In *Ex parte Max,*44 Cal. 580; it was said: "The application for the writ of *habeas corpus*made here proceeds upon the ground that the judgment, under the circumstances appearing, is not merely erroneous, but is void in the absolute sense, and so affords no authority to the warden of the prison to detain the petitioner. We are of opinion, however, that the position cannot be maintained. The indictment upon which the judgment is founded is sufficient in all respects. The offense of which the petitioner was convicted was one within the scope of the indictment, and the judgment one which the county court had the authority to render upon the appearance and plea of the petitioner. These conditions *391constitute jurisdiction. All others involve questions of mere error, and the latter cannot be inquired into upon writ of *habeas*corpus, but only upon proceedings in error. The obvious distinction between the office of a writ of error or an appeal, on the one hand, and a writ of *habeas corpus*upon the other, was not presented, but was overlooked in *Ex parte Ah Cha et al.,*40 Cal. 426, which was a writ of *habeas corpus*heard and determined at chambers, and that case must in that respect be overruled.”

In *Ex parte Mooney,*26 W. Va. 36, 53 Am. Rep. 59, it was held that, where the court has jurisdiction of the subject-matter and of the person, and pronounces a severable judgment or sentence, one part of which is authorized by law, and another distinct part which is not authorized, the prisoner will not be discharged, on *habeas corpus,*when it does not appear that he has undergone the full punishment imposed by the legal portion of the sentence. It was said that, as to that part which the court had the power to pronounce, the sentence was valid upon proceeding for *habeas corpus-,*that errors which rendered the judgment merely voidable and not absolutely void could not be inquired into under such a writ (citing *In re Prime,*1 Barb. 340; *State*v. *Shattuck,*45 N. H. 211; *Ross’ Case,*2 Pick. 171; *Ex parte Watkins,*3 Pet. 201, 7 L. Ed. 650), and that, if the judgment is in excess of that which the court rendering it by law had the power to pronounce, such judgment is void for the excess only (citing *Brook’s Case,*4 Leigh, 669; *Murry's Case,*5 Leigh, 724; *Sail’s Case,*6 Leigh, 615, 29 Am. Dec. 236; *People*v. *Liscomb,*60 N. Y. 560, 19 Am. Rep. 211; *Feeley’s Case,*12 Cush. 598; *Ex parte Shaw,*7 Ohio St. 81, 70 Am. Dec. 55; *People*v. *Markham,*7 Cal. 208; *People*v. *Baker,*89 N. Y. 467.)

At page 43 of 26 W. Va., in regard to the Missouri case *(Ex parte Page)*relied upon here by petitioner and cited above, it was said: "But, if that case could be regarded as decided upon principle, it-must be disapproved, since it is not only contrary to the general rules hereinbefore stated, but it is in positive conflict with numerous other and seemingly better considered decisions of courts of other states. *392
      *(In re Petty,*22 Kan. 277; *Ex parte Parks,*93 U. S. 18, 23 L. Ed. 787; *People*v. *Jacobs,*66 N. Y. 9; *People*v. *Liscomb,*60 N. Y. 559,19 Am. Rep. 211; *People*v. *Balter,*89 N. Y. 460.)”

In *People*v. *Cavanagh,*2 Parker, Cr. R. 66, release was sought from an erroneous sentence and imprisonment. It was held that there was no force in the point raised that the defendant should have been sentenced to the penitentiary and not to the county jail; that, if it were error to designate the county jail as the place of confinement, it could not be reviewed and corrected in a *habeas corpus*proceeding, and was no ground for his discharge.

In *Ex parte Bond,*9 S. C. 80, 30 Am. Rep. 20, the prisoner had been convicted of an assault with intent to kill, and sentenced to confinement at hard labor in the penitentiary. The court held that the offense was not punishable by imprisonment in the state penitentiary; that the sentence was therefore erroneous, but not void, and refused to discharge the petitioner on *habeas corpus.*

In *People*v. *Kelly,*97 N. Y. 212, upon a conviction for assault in the third degree, the sentence was to imprisonment at hard labor in the state prison for one year. The court of appeals held that the offense was a misdemeanor, that the sentence was excessive upon a valid conviction, but refused to discharge the prisoner and remanded him to the sheriff to be further dealt with by the trial court.

In *Re Graham,*74 Wis. 451, 43 N. W. 148, 17 Am. St. Rep. 174, it was held that a judgment sentencing a person to imprisonment for a longer term than the statute authorizes is merely erroneous, and not void for want of jurisdiction. The court proceeded: "We deny the writs, for the reason that the error in the judgments does not render them void, or the imprisonment under them illegal, in,that sense which entitles them to be discharged on a writ of *habeas corpus.*The judgments are doubtless erroneous, and would be reversed on writ of error. *(Fitzgerald*v. *State,*4 Wis. 395; *Kaney*v. *State,*5 Wis. 529; *Benedict*v. *State,*12 Wis. 314; *Peglow v. State,*12 Wis. 534.) But the judgments are not void. *(State ex rel. Welch*v. *Sloan,*65 Wis. 647, 27 N. W. 616.) The court had jurisdiction of the persons and subject-matter or offense, *393but made a mistake in the judgment. For mere error, no matter how flagrant, the remedy is not by *habeas corpus.*The law is well settled in this court that on *habeas corpus*only jurisdictional defects are inquired into. The writ does not raise questions of errors in law or irregularities in the proceedings. *(In re Crandall,*34 Wis. 177; *In re Pierce,*44 Wis. 444.)”

In *Ex parte Van Hagan,*25 Ohio St. 432, sentence had been pronounced under a statute which had been repealed. The Supreme Court of Ohio stated: "The punishment inflicted by the sentence, in excess of that prescribed by the law in. force, was erroneous and voidable, but not absolutely void. It follows that a writ of error to reverse the proceedings or sentence is the remedy that the relator should have resorted to in order to obtain a discharge from illegal imprisonment, and not *habeas corpus,*which is not the proper mode of redress where the relator was convicted of a criminal offense and erroneously sentenced to excessive imprisonment therefor by a court of competent jurisdiction. *Ex parte Stephen M. Shaw,*7 Ohio St. 81, 70 Am. Dec. 55, approved and followed on this point.”

In *Sennot’s Case,*146 Mass. 489, 16 N. E. 448, 4 Am. St. Rep. 344, it was claimed that the commitment of a juvenile offender to the state board, to be sent to the Lyman School, was not authorized and was not the proper place. The Supreme Court of Massachusetts said: "If there was in the sentence or the prior proceedings any irregularity affecting the validity of the judgment, it can be corrected upon a writ of error. But neither irregularities nor errors, so far as they were within the jurisdiction of the court, can be inquired into upon a writ of *habeas corpus. (Clarke's Case,*12 Cush. 320; *Herrick*v. Smith, 1 Cray, 1, 50, 61 Am. Dec. 381; *Adams*v. *Vose,*1 Gray, 51; *Ex parte Watkins,*3 Pet. 193, 7 L. Ed. 650; *Ex parte Siebold,*100 U. S. 371, 373, 25 L. Ed. 717; *In re Underwood,*30 Mich. 502; *Platt v. Earrison,*6 Iowa, 79, 71 Am. Dec. 389.) That a writ of *habeas corpus*cannot perform the functions of a writ of error, in relation to proceedings of a court within its jurisdiction, is universally agreed. The only conflict of authority touching the *394subject is in regard to what acts are open to inquiry upon the question of jurisdiction. It is held in this state, and by good authorities elsewhere, that the constitutionality of a law which a court is attempting to apply lies at the foundation of the jurisdiction under it, and may be called in question upon *habeas corpus. (Herrick*v. Smith, 1 Gray, 1, 49, 61 Am. Dec. 381; *Ex parte Siebold,*100 U. S. 371, 25 L. Ed. 717; *People*v. *Roff,*3 Parker, Cr. R. 216.) But this doctrine has been contradicted, and action founded upon an unconstitutional law has been held a mistake which can only be corrected upon a writ of error. *(In re Harris,*47 Mo. 164.) So there has been diversity of opinion among different courts as to sentences which are not authorized by law. The better rule seems to be that where a court has jurisdiction of the person, and of the offense, the imposition by mistake of a sentence in excess of what the law permits is within the jurisdiction, and does not render the sentence void, but only voidable by proceedings upon a writ of error. *(Ross’ Case,*2 Pick. 165; *Feeley’s Case, 12*Cush. 598, 599; *Semler, Petitioner,*41 Wis. 517; *Ex parte Shaw,*7 Ohio St. 81, 70 Am. Dec. 55; *Ex parte Van Hagan,*25 Ohio St. 426; *Phinney, Petitioner,*32 Me. 440; *Kirby*v. *State,*62 Ala. 51; *Lark*v. *State,*55 Ga. 435.) It has sometimes been held that such a sentence is legal so far as it is within the provisions of law, and void as to the excess. *(People*v. *Jacobs,*66 N. Y. 8; *People*v. *Baker,*89 N. Y. 460; *Bigelow*v. *Forrest,*9 Wall. 339, 19 L. Ed. 696.)”

Extracts from other decisions pertinent to the inquiry at hand are:

Justice Holmes, speaking for the court, in *Be Stalker,*167 Mass. 12, 44 N. E. 1068, said: "We assume, as contended for the petitioner that there was error in his sentence because it did not include solitary imprisonment. *(Lane*v. *Commonwealth,*161 Mass. 120, 122, 36 N. E. 755.) But on a writ of error this could be corrected. (Pub. St. 1882, c. 187, sec. 13; *Jacquins*v. *Commonwealth,*9 Cush. 279.) * * * Manifestly, it would be an absurd result if the petitioner could get his discharge on *habeas corpus*when he could not get it by a regular proceeding to reverse his sentence. But whether *395the sentence could be corrected or could not be, the rule which has been approved by this court denies relief by *habeas corpus*when the court has jurisdiction to sentence the petitioner, and errs simply in regard to the éxtent of the punishment. *(Sennot’s Case,*146 Mass. 489, 492, 493, 16 N. E. 448, 4 Am. St. Rep. 344; *Feeley’s Case, 12*Cush. 598, 599.) See *Ex parte Bigelow,*113 U. S. 328, 5 Sup. Ct. 542, 28 L. Ed. 1005; *In re Belt,*159 U. S. 95, 15 Sup. Ct. 987, 40 L. Ed. 88.”

*Petition of Bishop,*172 Mass. 36, 51 N. E. 191: "The general rule is that where the court has jurisdiction, and errs merely in regard to the punishment, relief will not be granted by *habeas corpus,*but that the remedy is by a writ of error, in which the mistake can be corrected and such sentence pronounced as should have been imposed. *(Ross’ Case,*2 Pick. 165, 172; *Sennot’s Case,*146 Mass. 489, 16 N. E. 448, 4 Am. St. Rep. 344; *Stalker, Petitioner,*167 Mass. 11, 44 N. E. 1068; *Ex parte Bigelow,*113 U. S. 328, 5 Sup. Ct. 542, 28 L. Ed. 1005; *In re Belt,*159 U. S. 95, 15 Sup. Ct. 987, 40 L. Ed. 88.) In exceptional cases relief may be granted by *habeas corpus,*or questions of constitutionality considered. *(Feeley’s Case,*12 Cush. 598; *Plumley’s Case,*156 Mass. 236, 30 N. E. 1127, 15 L. R. A. 839.) We discover nothing in this case which takes it out of the general rule.”

*In re Belt,*159 U. S. 100, 15 Sup. Ct. 988, 40 L. Ed. 88: " The general rule is that the writ of *habeas corpus*will not issue unless the court, under whose warrant the petitioner is held, is without jurisdiction; and that it cannot be used to correct errors. Ordinarily, the writ will not lie where there is a remedy by writ of error or appeal; but in rare and exceptional cases it may be issued, although such remedy exists.”

*Elsner*v. *Shrigley,*80 Iowa, 35, 45 N. W. 393: "In *Jackson*v. *Boyd,*53 Iowa, 536, 5 N. W. 734, it is expressly stated that a failure to fix the time in the judgment 'would not render it void’; and also 'the extent of the imprisonment is fixed and declared by the statute, and when the defendant has been imprisoned the required length of time he is entitled to be discharged.’ Without attaching to this language a broader signification than is required by the facts considered, it sustains the view that the law is a limitation as to the extent of *396the imprisonment, when no time is fixed in tbe judgment, and is against the view that the judgment is void because under it the imprisonment might be'indefinite’; that is, to the time of the actual payment of the judgment. We reach the conclusion that *habeas corpus*is not available to question the correctness of the proceedings of the district court with reference to the judgment in question. Our conclusion has support, more or less direct, in many cases, and among them are *Turney*v. *Barr,*75 Iowa, 758, 38 N. W. 550; Hurd. Hab. Oorp. 2d ed. 328; Cooley, Const. Lim. 347; *Shew*v. *McHenry,*52 Iowa, 182, 2 N. W. 1096; *State*v. *Orton,*67 Iowa, 554, 25 N. W. 775; *Platt*v. *Harrison,*6 Iowa, 79, 71 Am. Dec. 389; *Zelle*v. *McHenry,*51 Iowa, 572, 2 N. W. 264; *Herrick*v. *Smith,*1 Gray, 50, 61 Am. Dec. 381; *Adams*v. *Vose,*1 Gray, 51; *Ex parte Watkins,*3 Pet. 193, 7 L. Ed. 650; *Ex parte Siebold,*100 U. S. 371, 25 L. Ed. 717; *In re Underwood,*30 Mich. 502; *Ross’ Case,*2 Pick. 165; *Feeley’s Case,*12 Cush. 598; *Semler, Petitioner,*41 Wis. 517; *Exparte Shaw,*7 Ohio St. 81, 70 Am. Dec. 55; *Ex parte Van Hagan,*25 Ohio St. 426; *Phinney, Petitioner,*32 Me. 440; *Kirby*v. *State,*621 Ala. 51; *People*v. *Liscomb,*60 N. Y. 559, 19 Am. Rep. 211; *Sennot’s Case,*146 Mass. 489, 16 N. E. 448, 4 Am. St. Rep. 344; *Ex parte Lange,*18 Wall. 163, 21 L. Ed. 872. It is said the judgment of imprisonment, by not fixing a limit, is indefinite; but the law itself defeats sucha claim, for beyond its limits the judgment is void, and this proceeding is available for protection against illegal imprisonment.”

In *People*v. *Kelly,*97 N. Y. 212, the defendant had been convicted of assault in the third degree and .sentenced to imprisonment at hard labor in the state prison, and it was held that, while the sentence was void, as the conviction was valid, the prisoner was not entitled to discharge upon *habeas corpus,*but should be remanded to the custody of the sheriff.

In *Re Harris,*68 Vt. 243, 35 Atl. 55, on *habeas corpus,*it appeared that the petitioner was properly convicted. The sentence of imprisonment in the state prison was void. It was held that, while he was unlawfully in the state prison, he was not unlawfully restrained, and should be remanded *397to the sheriff of the county in which he was convicted, to be resenteneed.

In *Ex parte*McGuire, 135 Cal. 339, 67 Pac. 327, Am. St. Rep. 105, it was held that the writ of *hateas corpus*lies not only when the prisoner is entitled to his liberty, but also when he is held by one person, and another is entitled to his custody. Chief Justice Beatty, speaking for the court, said: " My conclusion is that the imprisonment of the petitioner in the county jail, in execution of his sentence for the misdemeanor, is unwarranted and illegal; but it does not follow, as he contends, that he should be set at liberty. He is entitled to the benefit of the writ of *hateas corpus*only so far as necessary to secure him in his legal right to be placed in the proper custody. It is therefore ordered that he be remanded to the custody of the sheriff for the purpose of delivery forthwith to the warden of the state prison.”

In *Kingen*v. Kelley, 28 Pac. 44, 3 Wyo. 566, 15 L. R. A. 177, the court quoted approvingly from *O’Brien*v. *Barr,*49 N. W. 68, 83 Iowa, 51: " 'The imprisonment and its duration could alone be determined by the court. But fixing the particular penitentiary in which the petitioner should be confined is not a part of the judgment. The. effect and duration of confinement is all that was judicially determined by the judgment.’”

In *Ex parte Waterman,*33 Fed. 29, the petitioner was sentenced to hard labor in the state prison at Auburn for three years, but the marshal ascertained on his arrival with her that the state law did not allow female prisoners in that institution. Later the court, in her absence, made an order substituting the Erie County penitentiary. The court denied the petition for writ of *hateas corpus,*and remanded the prisoner, on the ground that the order fixing the place of imprisonment was not necessarily a part of the judgment.

In *Re McDonald,*33 Pac. 22, 4 Wyo. 150, the court cited with approval *Eisner*v. *Shrigley, supra,*and *People*v. *Poster,*104 Ill. 156, and said: "The judgment * * * does not in itself fix the term or rate of imprisonment for the failure to pay * * * the fine imposed; but, if this were erroneous, *398it could only be reached by proceedings in error. It is not the office of a writ of *habeas corpus*to correct errors or irregularities of a trial court.”

*In re*Bonner, 151 U. S. 258, 259, 260, 14 Sup. Ct. 323, 326, 327, 38 L. Ed. 149: "When the jury have rendered their verdict, the court has to pronounce the proper judgment upon such verdict, and the law, in prescribing the punishment, either as to the extent, or the mode, or the place of it, should be followed. If the court is authorized to impose imprisonment, and it exceeds the time prescribed by law, the judgment is void for the excess. If the law prescribes a place of imprisonment, the court cannot direct a different place not authorized. It cannot direct imprisonment in a ■penitentiary, when the law assigns that institution for imprisonment under judgments of a different character. * * * A question of some difficulty arises, which has been disposed of in different ways, and that is as to the validity of a judgment which exceeds in its extent the duration of time prescribed by law. With many courts and judges — perhaps with the majority — such judgment is considered valid to the extent to which the law allowed it to be entered, and only void for the excess. * * * The prisoner is ordered to be confined in the penitentiary, where the law does not allow the court to send him for a single hour. To deny the writ of *habeas corpus*in such a case is a virtual suspension of it, and it should be constantly borne in mind that the writ was intended as a protection of the citizen from encroachment upon his liberty from any source, equally as well from the unauthorized acts of courts and judges as the unauthorized acts of individuals. * * * The judges of all courts of record are magistrates, and their object should be. not to turn loose upon society persons who have been justly convicted of criminal offenses, but, where the punishment imposed, in the mode, extent, or place of its execution, has exceeded the law, to have it corrected by calling the attention of the court to such excess. We do not perceive any departure from principle or any denial of the petitioner’s right in adopting such a course. He complains of the unlawfulness of his place of imprisonment. He is only *399entitled to relief from that unlawful feature, and that be would obtain if opportunity be given to that court for correction in that particular. * * * Some of the state courts have expressed themselves strongly in favor of the adoption of this course, where the defects complained of consist only in the judgment, in its extent, or mode, or place of punishment, the conviction being in all respects regular. In *Beale*v. Commonwealth, 25 Pa. 11, 22; the Supreme Court of Pennsylvania said: 'The common law embodies in itself sufficient reason and common sense to reject the monstrous doctrine that a prisoner, whose guilt is established, by a regular verdict, is to escape punishment altogether, because the court committed an error in passing the sentence. If this court sanctioned such a rule, it would fail to perform the chief duty for which it was established.’ ”

This court has decided that the writ of *habeas corpus*is not intended to take the place of an appeal, writ of error, or *certio-*rari, and cannot be used for the purpose of reviewing errors or irregularities in the proceedings of a court having jurisdiction (E*x parte*Smith, 2 Nev. 338; *Ex parte Maxwell,*11 Nev. 428; *Ex parte Winston,*9 Nev. 71; *Ex parte Twohig,*13 Nev. 302; *Ex parte- Bergman,*18 Nev. 331, 4 Pac. 209); that, if the prisoner is held under a valid commitment, the legality of other commitments need not be considered until his term of service under the good commitment has expired *(Ex parte Ryan,*17 Nev. 139, 28 Pac. 1040; *Ex parte Ryan,*10 Nev. 261); that under this writ the court will review the question of the constitutionality of an act under which petitioner has been convicted, and if the act is unconstitutional discharge him *(Ex parte Rosenblatt,*19 Nev. 439,14 Pac. 298, 3 Am. St. Rep. 901; *Ex parte Boyce,*27 Nev. 299, 75 Pac. 1, 65 L. R, A. 47; *Ex parte Bair,*28 Nev. 127, 80 Pac. 463, and eases therein cited); that the petitioner will be released from an order committing him for contempt for an act not committed in the immediate view of the court, when the court was without jurisdiction to make such order by reason of its failure to first require an affidavit and to cite the offender to show cause why he should not be punished *(Ex parte Hedden,*29 Nev. 352, 90 Pac. 737); and that the addition of the words *400"at bard labor” in the sentence, although not authorized by-statute, would be treated as mere surplusage and in no manner-affecting the validity of the judgment *(Ex parte*Maher, 25 Nev. 424, 62 Pac. 1).

From these cases it is apparent that a few courts have held that, where the sentence upon a valid conviction is excessive or erroneous in part, the whole of the judgment must fall as being without the jurisdiction of the court, and that the convicted criminal must be discharged, while others hold' that the sentence may be corrected and the proper punishment inflicted, others that it is void only as to the excessive punishment it orders, others that the erroneous sentence will stand and be enforced against *habeas corpus*proceedings, and can only be attacked or corrected by the regular methods of' appeal or writ of error, and still other courts, among which are notably the Supreme Courts of the United States, of Massachusetts, and Nevada, adhere to the latter rule generally, but allow some elasticity and exceptions for the correction of errors, where the petitioner is restrained under an unconstitutional act, or there is some special urgency and hardship, and the sentence was wholly or partly unauthorized.

If the rule, supported by the decisions upon which petitioner relies, holding that the sentence is void where it specifies a longer period, or different place for the imprisonment, or a heavier fine, than the statute warrants, was adopted by this court, it might lead to grave injustice in the future, for under it, in cases having some omission or mistake in the judgment, criminals sentenced after due conviction of the most heinous crimes would have to be released and turned' loose upon the community. If, after conviction of murder in the first degree, the district court should sentence the accused to be hanged in the yard of the county, jail under the former law and the practice in this commonwealth, instead of at the state prison, under the more recent statute now in force, the sentence would be void, and the defendant would have to be discharged. Justice ought not to be thwarted by such strained technicalities. We cannot favor such a rule, and we are impelled to join those courts which have determined against it.

*401It will be perceived that section 2267, Comp. Laws, is the only one which specifies the place of imprisonment in lieu of the payment of a fine, and that it directs that, whenever a prisoner, upon conviction for any criminal offense, fails to pay the fine, the district court may imprison him in the county jail at the rate of $2 per day until the fine or forfeiture imposed shall have been satisfied. In this connection no distinction is made in regard to the grade of the crime, and there is no limitation to misdemeanors. Under section 4701, the defendant was guilty of a felony, and could have been sentenced directly to the state prison for not less than one nor exceeding two years, or to pay a fine of not less than $1,000 nor exceeding $5,000, or to both. But the language of this section does not provide for confinement in the state prison or elsewhere in lieu of the payment of the fine, and there is nothing in this section or the others which authorized the court to commit the defendant to the state prison upon his failure to pay.

And when we turn to section 2267, the one which does provide for imprisonment as an alternative in lieu of nonpayment, the language fixes the place of confinement as such alternative in all cases, and without making any distinction between felonies and misdemeanors, at the county jail. The fine imposed was authorized, being the minimum amount specified in the statute, and the judgment follows the other provisions in ordering that the defendant be imprisoned at the rate of $2 per day upon his failure to pay the fine. The only error in the sentence was the direction that the defendant work out the fine in the state prison, when the statute specifies the county jail. If he had been fined the maximum of $5,000, instead of $1,000, it would take him about seven years to work out the fine at the rate of $2 per day. Whether it would be better to have a statute, such as exists in some states, providing that where the fine exceeds $500, or a specified amount, or the imprisonment may exceed six months or one year, the confinement in lieu of the payment of a fine shall be in the state prison, is a matter for the legislature, and not for the courts, to regulate. It is our duty to enforce these statutes as we find them.

*402The sentence being in accordance with the law and within the discretion vested in the district court as to the amount of the fine and the time of the alternative imprisonment imposed, and being erroneous only as to a matter which is definitely fixed by the statute, the place of confinement, and regarding which no court has any discretion or power to change, it seems unnecessary to have the judgment of the district court modified, even if the mistake may be considered as one apparent upon the record and of the kind usually corrected by courts upon mere suggestion or of their own volition. The direction that the confinement be in the state prison may be rejected as surplusage and of no force or effect, in the face of the statute which controls and fixes the county jail as the place of imprisonment, without it being so designated in the judgment. There was a necessity for the correction of the sentence as ordered by the Supreme Court of the United States in the Bonner case, which does not exist here. When it was held there that imprisonment in the penitentiary was not authorized by the federal statute, it became necessary for the trial court to exercise the discretion vested in it and correct the sentence by designating some one of the different jails it had power to select, no particular one of which was fixed by the statute for the imprisonment, as in this state.

The warden of the state prison is directed to deliver the petitioner to the sheriff of Washoe County upon his appearance and demand at the state prison and the latter is ordered to take the petitioner into custody, and detain him in the county jail of that county for the remainder of the term of imprisonment imposed by the sentence of the district court, unless that part of the fine remaining unsatisfied is sooner paid.