Henry C. Luce, presently confined in San Quentin Prison serving a sentence for felony indecent exposure (Pen. Code, § 314), seeks discharge by writ of habeas corpus (see People v. Dowding, 185 Cal.App.2d 274, 276-277 [8 Cal.Rptr. 208]). His petition is predicated on the ground that a prior conviction for a like offense, which was used to elevate the present offense from misdemeanor to felony status (see Pen. Code, § 314, subd. 2, par. 2), was entered upon a plea of guilty made without apprisal or awareness of his right to counsel or waiver of such right.
A certified abstract of the record of the prior proceeding reflects that in 1950, in the Municipal Court for the Oakland-Piedmont Judicial District, County of Alameda, petitioner was charged with indecent exposure in violation of section 311 of the Penal Code, presently section 314, subdivision 1 (Stats. 1961, ch. 2147, §§ 1, 7), a misdemeanor. He initially pleaded not guilty, but later changed his plea to guilty. Concerning legal representation at the time he changed his plea to guilty, the certified abstract merely states that “Court docket does not show of record that any defense attorney was present.” Petitioner was placed on probation and ordered to serve 180 days in the county jail, the maximum period of confinement for misdemeanor indecent exposure.
In 1964, in the Superior Court for the City and County of San Francisco, petitioner was charged with indecent exposure under subdivision 1 of section 314 of the Penal Code. Subdivision 2, paragraph 2, of section 314 provides that “Upon the second and each subsequent conviction under subdivision 1 of this section, . . . every person so convicted is guilty of a felony, and is punishable by imprisonment in state prison for not less than one year.” Because of the prior 1950 conviction which was charged against him in 1964, petitioner was sentenced as a felon to state prison for the term provided by law, a maximum of life imprisonment (see Pen. Code, § 671) and was transferred to the custody of the Department of Corrections on April 22, 1964. Petitioner was represented by counsel in the 1964 proceeding, and no questions are here presented concerning the adequacy of that representation.
*13However, as to the 1950 proceeding, petitioner alleges that he was not represented by counsel, that he was indigent, that he was never apprised of his right to counsel, and that he did not waive that right by word or act. Accordingly, he urges that there was a constitutional defect in that proceeding (Gideon v. Wainwright, 372 U.S. 335 [83 S.Ct. 792, 9 L.Ed.2d 799, 93 A.L.R.2d 733]) rendering it subject to collateral attack (United States ex rel. Durocher v. LaVallee, 330 F.2d 303; In re Johnson, 62 Cal.2d 325 [42 Cal.Rptr. 228, 398 P.2d 420]) ; that the 1964 judgment is therefore valid only insofar as it determines that he is guilty of misdemeanor indecent exposure and imposes sentence for that lesser crime (see In re Seeley, 29 Cal.2d 294, 302-303 [176 P.2d 24]) ; and that he is presently entitled to be discharged from custody because he has already served in excess of the maximum sentence for misdemeanor indecent exposure. (Pen. Code, §§ 19 ; 314, subd. 1.)
In the return to our order to show cause respondent, though stating that “there are no available records which of themselves would effectively controvert petitioner’s allegations,” denied those allegations on the basis of an affidavit of the judge who presided over the 1950 proceeding, the Honorable Chris B. Fox, retired. Judge Fox states that while he has “no independent recollection of the proceedings against the petitioner” in his court, it was his “universal practice upon arraignment and upon change of plea to guilty to advise any defendant charged with a serious misdemeanor, such as Mr. Luce, of his constitutional rights, particularly of his right to be represented by counsel throughout the proceedings.” The judge continues; “ [T]here was at all times a Deputy Public Defender in my court room during arraignment and sentencing proceedings whose services were available to any indigent defendant who wished to be represented by counsel. Because of the practice that prevailed in my court, it is not true that petitioner Luce was never afforded the opportunity to secure the services of the Public Defender or court-appointed counsel and was unaware of the right to have an attorney appointed for him.”
This court has held that “Evidence of a custom or practice of the arraigning judge may be considered in a habeas corpus proceeding for the purpose of explaining or filling certain gaps in the official record.” (In re Johnson, supra, 62 Cal.2d 325, 331.) Judge Fox’s affidavit is therefore persuasive evidence that petitioner was apprised by the court of his right *14to the services of court-appointed counsel. Further, petitioner’s reply to the return herein appears to concede that he was so apprised. We therefore determine that petitioner was properly advised of his constitutional right to legal assistance prior to his entry of a guilty plea.
We are thus brought to the question of waiver. Petitioner here alleges that he did not by word or act waive his constitutional right to counsel, and that allegation is controverted in the return to our order to show cause. We have today held that, in the context of such conflicting allegations, a plea of guilty entered by one advised of his constitutional right to legal assistance raises a fact issue as to whether an effective waiver of that right occurred with the entry of the plea. (In re Woods, ante, p. 3 [48 Cal.Rptr. 689, 409 P.2d 913].) Further, the determination of the issue thus raised depends in each case upon the particular facts and circumstances surrounding that case, including the background, experience, and conduct of the accused. (In re Woods, supra, ante, p. 8; In re Johnson, supra, 62 Cal.2d 325, 335.)
In Woods we concluded that the hearing on the fact issue thus raised would best be conducted by the court which had rendered the judgment establishing habitual criminal status on the basis of the two questioned priors there involved. In the instant case similar considerations require that the indicated hearing be conducted by the court which rendered judgment of felony indecent exposure on the basis of the questioned prior here involved.
The writ is granted and the Superior Court of San Francisco County is directed to redetermine petitioner’s status under subdivision 2, paragraph 2, of Penal Code section 314 in further proceedings in accordance with the views expressed herein.
Traynor, C. J., McComb, J., Peters, J., Tobriner, J., Mosk, J., and Burke, J., concurred.