The conviction of the relator was valid. Penal' Code, § 571. He, therefore, is not entitled to his discharge, because he should suffer proper punishment People ex rel Devoe v. Kelly, 2 N. Y. Crim. 428. But he was convicted before a Court of Special Sessions held by a justice of the peace. Whatever punishment a court of record might impose upon conviction for this offense, a Court of Special Sessions is restricted by section 717, Code of Criminal Procedure: “ The fine cannot exceed fifty dollars nor the imprisonment six months.” Here-the fine was two hundred and fifty dollars, with this addition, “ and stand committed to the county jail of Ulster county until the fine be satisfied, not exceeding one year.” Section 718, Code of Criminal Procedure, provides that: “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 cannot exceed one day for every one dollar of the fine.” These sections are in Part V, entitled “ of proceedings in Courts of Special Sessions and Police Courts.” Section 718-is a transcript of section 484 in Part IY, entitled “of the proceedings in criminal actions prosecuted by indictment” It thus seems that the days of imprisonment cannot exceed the dollars of fine in any court. We think a Court of Special Sessions could not pronounce the sentence thus imposed.
The suggestion is made that the sentence is valid to the-extent of fifty dollars and a liability to fifty days’ imprisonment We think not, non constat, that the relator would not, *111immediately have paid the fifty dollars if that had been imposed, and thus have escaped imprisonment altogether. Two hundred and fifty dollars may be quite beyond his ability to pay. Thus the illegal sentence confines him in jail where a legal one might not, and in this respect the case is distinguished from People ex rel. Trainor v. Baker (89 N. Y. 460).
People v. Kelly is authority to the effect that a writ of habeas corpus is the proper remedy. The relator is detained upon an invalid judgment; it needs a valid one lawfully to detain him. Section 2016, Code of Civil Procedure, denies habeas corpus to a person “ when he has been committed or is detained by virtue of the final judgment or decree of a competent tribunal.” It was held in People ex rel. Tweed v. Liscombe (60 N. Y. 559), as explained in People ex rel. Wolf v. Jacobs (66 id. 10), that • when in pronouncing its sentence the court has exhausted its authority, if it proceed further to impose additional sentence, such additions are void. Thus “ the final judgment ” must be “ of a competent tribunal,” and where the competency to pronounce it is exhausted or never existed, it does not come within the definition of the final judgment as to which habeas corpus is ineffective.
It is suggested that the relator’s remedy is by appeal No doubt upon appeal the court could set aside the illegal judgment and pronounce a legal one (Code Crim. Pro. §§ 543, 764); but meantime it is true that the relator is unlawfully detained upon an invalid sentence, and he should be speedily freed from that restraint, since we cannot detain bim upon this sentence, and in this proceeding cannot ourselves pronounce any, and it is impracticable to remand him to the Court of Special Sessions; we must discharge him.
The order of the county judge is reversed and the relator discharged.
Learned, P. J., concurs.