
143 S.E.2d 133 (1965)
STATE ex rel. James E. BULLETT
v.
Otto C. BOLES, Warden, West Virginia Penitentiary.
No. 12480.
Supreme Court of Appeals of West Virginia.
Submitted June 29, 1965.
Decided July 6, 1965.
*134 Katherine A. Yost, Charleston, for relator.
Atty. Gen. C. Donald Robertson, Asst. Atty. Gen. George H. Mitchell, Charleston, for respondent.
HAYMOND, Judge.
This is an original habeas corpus proceeding instituted in this Court on June 21, 1965. The petitioner, James E. Bullett, seeks a writ to release him from the penitentiary of this State where he is now confined as a prisoner under a sentence of life imprisonment imposed by the final judgment of the Circuit Court of Morgan County, West Virginia, rendered September 4, 1947.
On June 21, 1965, this Court issued a writ returnable June 29, 1965 and appointed counsel to represent the petitioner in this proceeding. Upon the return day of the writ the defendant, Otto C. Boles, Warden of the West Virginia Penitentiary, produced the petitioner in open court in obedience to the command of the writ, and filed his answer; and this proceeding was submitted for decision upon the petition and its exhibits, the answer and its exhibits, and the written brief and the oral argument of the attorney for the petitioner.
According to the record the petitioner entered a plea of guilty to an indictment for the crime of burglary at the April 1938 term of the Circuit Court of Morgan County, West Virginia, and on April 5, 1938, he was sentenced to confinement in the penitentiary of this State for an indeterminate period of one year to five years; on September 2, 1941, in the Circuit Court of Morgan County, West Virginia, the petitioner also entered a plea of guilty to an indictment for felonious assault and he was sentenced to confinement in the penitentiary of this State for an indeterminate period of one year to five years; and on September 4, 1947, the petitioner was convicted by a jury in the Circuit Court of Morgan County, West Virginia, on an indictment for felonious assault and at that time the prosecuting *135 attorney filed an information charging the petitioner with the 1938 and 1941 felony convictions and the petitioner was then sentenced to imprisonment for life in the penitentiary of this State under the habitual criminal statute, Sections 18 and 19, Article 11, Chapter 61, Code, 1931, as amended.
The petitioner contends that the sentence of life imprisonment is unconstitutional, null and void for the reason that he was denied the assistance of counsel to defend him in the criminal proceedings in 1938 and 1941.
The record indicates and the defendant asserts that the petitioner was represented by counsel in the criminal proceeding in 1941 but the record is silent as to whether he was represented by counsel or whether he was advised as to his right to the assistance of counsel and intelligently waived such right in the criminal proceeding in 1938. This is conceded by the defendant. The record also shows that the petitioner was represented by counsel upon the trial of the principal offense in September 1947 but it does not show whether the petitioner was duly cautioned as required by the recidivist statute of this State.
Though the record is silent as to whether the petitioner was duly cautioned, it will be presumed, under the general rule, that the court performed its duty in every respect as required by law, except as to the matter of the assistance of counsel which, being a fundamental constitutional right, will not be presumed to have been waived. State ex rel. Pettery v. Boles, W.Va., 139 S.E.2d 263; State ex rel. Massay v. Boles, W.Va., 140 S.E.2d 608; State ex rel. Arbraugh v. Boles, W.Va., 139 S.E. 2d 370; State ex rel. Browning v. Boles, W.Va., 139 S.E.2d 263; State ex rel. Stumbo v. Boles, W.Va., 139 S.E.2d 259; State ex rel. Hicklin v. Boles, W.Va., 139 S.E.2d 182; State ex rel. May v. Boles, W. Va., 139 S.E.2d 177; State ex rel. Powers v. Boles, W.Va., 138 S.E.2d 159; State ex rel. Browning v. Tucker, 142 W.Va. 830, 98 S.E.2d 740; State ex rel. Lovejoy v. Skeen, 138 W.Va. 901, 78 S.E.2d 456, certiorari denied, 349 U.S. 940, 75 S.Ct. 786, 99 L.Ed. 1268.
Inasmuch as the record does not indicate that the petitioner was accorded his right to the assistance of counsel in connection with his conviction of a felony in 1938, it will be presumed, in the absence of any showing to the contrary, that he was denied that right and that it was not intelligently waived and, in consequence, his conviction and sentence for the first of the two convictions and sentences mentioned in the information for which he was sentenced to the penitentiary on April 5, 1938 are void and cannot constitute the basis for the sentence of imprisonment for life imposed by the circuit court by its judgment of September 4, 1947. State ex rel. Owens v. King, W.Va., 142 S.E.2d 880; State ex rel. Lovejoy v. Boles, W.Va., 142 S.E.2d 374; State ex rel. Hall v. Boles, W.Va., 142 S.E.2d 377; State ex rel. Waugh v. Boles, W.Va., 142 S.E.2d 62.
The second conviction mentioned in the information for which the petitioner was sentenced to the penitentiary upon his plea of guilty in the circuit court on September 2, 1941, is a valid prior felony conviction and his subsequent conviction of the principal offense on September 4, 1947, is also a valid conviction. The only valid sentence, however, which the circuit court, under the recidivist statute, had jurisdiction to impose was a sentence of two years to ten years for the principal offense, of which he was convicted on September 4, 1947, and an additional period of five years for the second conviction and sentence on September 2, 1941, mentioned in the information, or a total sentence of two years to fifteen years. The portion of the sentence of life imprisonment in excess of fifteen years is void and its enforcement will be and is prevented in this habeas corpus proceeding. A judgment *136 which is wholly void, or is void in part, is subject to collateral attack and enforcement of such judgment will be prevented in a habeas corpus proceeding. State ex rel. McClure v. Boles, W.Va., 142 S.E.2d 773; point 2, syllabus, State ex rel. Robison v. Boles, W.Va., 142 S.E.2d 55; point 5, syllabus, State ex rel. Beckett v. Boles, W.Va., 138 S.E.2d 851.
On the question of the validity of the sentence of life imprisonment this case is controlled by the decision of this Court in the recent case of State ex rel. Whytsell v. Boles, W.Va., 141 S.E.2d 70. In that case this Court held in points 1 and 2 of the syllabus that "The denial of the fundamental right of the defendant to the assistance of counsel in a criminal proceeding applies to and invalidates any prior conviction of an offense within the meaning of a recidivist statute, and such conviction and any sentence of imprisonment imposed upon it, being null and void because of such denial, can not justify or support the imposition of any additional punishment under such statute.", and "To justify the imposition, under the recidivist statute of this State, of a sentence in excess of the sentence provided for the principal offense, the previous conviction and sentence must be a valid conviction and sentence; and if such previous conviction and sentence are void they will not constitute the basis for the imposition of the punishment provided by such statute and, in that situation, such statute will be deemed to be wholly inapplicable." See also State ex rel. Lovejoy v. Boles, W.Va., 142 S.E.2d 374; State ex rel. Hall v. Boles, W.Va., 142 S.E.2d 377.
As the petitioner has been imprisoned since September 1947 and has served more than the valid maximum sentence of two years to ten years for the principal offense of which he was convicted and an additional period of five years under the recidivist statute of this State for one prior conviction of a felony, or a total maximum period of two years to fifteen years, which should have been imposed as provided by law, instead of the void sentence of imprisonment for life, he is entitled to immediate release from his present confinement in the penitentiary. State ex rel. Whytsell v. Boles, W.Va., 141 S.E.2d 70; State ex rel. Lovejoy v. Boles, W.Va., 142 S.E.2d 374; State ex rel. Hall v. Boles, W.Va., 142 S.E.2d 377. A person imprisoned under a void sentence of imprisonment for life, who has fully served the maximum sentence of imprisonment which should have been imposed as provided by law of two years to ten years for the principal offense of which he was convicted and an additional period of five years under the recidivist statute of this State, or a total maximum period of two years to fifteen years, will be released from custody by a writ of habeas corpus.
Prisoner released.
