
140 Cal.App.3d 526 (1983)
189 Cal. Rptr. 491
KEMPY JACKSON, Petitioner,
v.
THE SUPERIOR COURT OF THE CITY AND COUNTY OF SAN FRANCISCO, Respondent; THE PEOPLE, Real Party in Interest.
Docket No. AO18340.
Court of Appeals of California, First District, Division Three.
March 2, 1983.
*527 COUNSEL
Jeff Brown, Public Defender, Joan Nosse, Deputy Public Defender, Quin Denvir, State Public Defender, Kathleen Kahn and Joan W. Howarth, Deputy State Public Defenders, for Petitioner.
No appearance for Respondent. *528 George Deukmejian, Attorney General, Robert H. Philibosian, Chief Assistant Attorney General, William D. Stein, Assistant Attorney General, Eugene W. Kaster and Christopher J. Wei, Deputy Attorneys General, for Real Party in Interest.
OPINION
SCOTT, J.
This petition is brought by a defendant found not guilty by reason of insanity and committed to state hospital in 1969. Under In re Moye (1978) 22 Cal.3d 457 [149 Cal. Rptr. 491, 584 P.2d 1097], absent special proceedings, his insanity commitment can be no longer than his maximum term for the underlying crime. The trial court did not set the degree for his charged murder, but the Community Release Board (forerunner to the Board of Prison Terms) has set his maximum at life, the term for first degree murder. Petitioner seeks to have his term reset at the maximum for second degree murder, pursuant to Penal Code section 1192 or Penal Code section 1157. We conclude that the board erred in setting his term at the term for first degree murder without a judicial determination of degree. However, we do not foreclose the possibility of the prosecution proving in the trial court that petitioner's murder was of the first degree. We also confirm the prosecutor's right to seek a two-year extension of petitioner's commitment pursuant to Penal Code section 1026.5, subdivision (b)(2). We treat the petition as a request for habeas corpus and grant partial relief.
Petitioner was charged with murder (Pen. Code, § 187), with no degree specified. Though he initially pleaded not guilty and not guilty by reason of insanity, he then withdrew his plea of not guilty of the crime. The matter was heard September 8, 1969, by the court without jury and was submitted on the medical reports. The court found petitioner not guilty by reason of insanity and, because he had not recovered his sanity, ordered him confined in state hospital pursuant to Penal Code section 1026.
In 1978, the California Supreme Court decided in In re Moye, supra, 22 Cal.3d 457, that absent extended term proceedings based upon potential danger to society, a person committed because of a verdict of not guilty by reason of insanity could not be confined beyond the maximum term for the underlying offense. The following year, the Legislature adopted Penal Code section 1026.5 to provide a mechanism for setting maximum terms and seeking extended commitments.
Penal Code section 1026.5 provides that in the case of a person committed to state hospital or other treatment facility who committed a felony on or after July *529 1, 1977 (a determinate sentence law, or DSL defendant), "... The court shall state in the commitment order the maximum term of commitment, ... [which] shall mean the longest term of imprisonment which could have been imposed for the offense or offenses of which the person was convicted, ..." (Pen. Code, § 1026.5, subd. (a)(1).) In the case of an Indeterminate Sentence Law (ISL) defendant, such as petitioner, confined for a felony committed prior to July 1, 1977, "... the Board of Prison Terms shall determine the maximum term of commitment which could have been imposed ...," and the person may not be kept in actual custody longer than the maximum term, except for two qualifications. (Pen. Code, § 1026.5, subd. (a)(2).)
The first qualification is that after the board has set the term based upon the offenses involved in the commitment, "... if at least two of the members of the board after reviewing the person's file determine that a longer term should be imposed for the reasons specified in [Penal Code] Section 1170.2, a longer term may be imposed ..." after a hearing. (Pen. Code, § 1026.5, subd. (a)(2).)[1] Thus, much like the situation of an ISL inmate confined to state prison, an ISL defendant committed under Penal Code section 1026 may be given a "serious offender" hearing and receive a longer term than that dictated for the crimes leading to the commitment.
The second qualification is that a person having committed certain violent crimes, including murder, may be committed for an additional term of two years upon a petition to the court and a hearing where it is determined that the person "by reason of a mental disease, defect, or disorder represents a substantial danger of physical harm to others." (Pen. Code, § 1026.5, subds. (b)(1)-(b)(9).) No limit is set on the number of extensions.
In April of 1979, before the effective date of the new legislation, but in apparent reliance upon In re Moye, supra, 22 Cal.3d 457, the board (then called the Community Release Board) set petitioner's maximum commitment term at life, the maximum for first degree murder. Three years later, in April of 1982, petitioner filed an in propria persona request in the San Francisco Superior *530 Court that his offense be deemed second degree murder. On April 9, 1982, the court so ordered.
If petitioner's maximum commitment were reset for second degree murder, his term would be less than 10 years, and his release should have taken place several years ago. However, after the trial court set the degree of the offense at second, the prosecutor petitioned the court under subdivision (b) of Penal Code section 1026.5 for a two-year extension of the commitment, apparently seeking to run the two years from some time in 1982. Petitioner moved to dismiss the extension proceedings on the ground that the petition was untimely. He argued that it should have been brought within 90 days of the decision in In re Moye, supra, 22 Cal.3d 457. That motion was denied. On the same day the court also revoked its order deeming the offense second degree murder, vacated the extension hearing date, and ordered petitioner returned to the state hospital in Atascadero. This petition followed.

(1) Where the trial court did not determine the degree of the charged murder, is the degree automatically second degree, pursuant to Penal Code section 1192 or Penal Code section 1157?

Penal Code section 1192 provides: "Upon a plea of guilty, or upon conviction by the court without a jury, of a crime or attempted crime distinguished or divided into degrees, the court must, before passing sentence, determine the degree. Upon the failure of the court to so determine, the degree of the crime or attempted crime of which the defendant is guilty, shall be deemed to be of the lesser degree."
Penal Code section 1157 provides in part: "Whenever a defendant is convicted of a crime ... which is distinguished into degrees, the jury, or the court if a jury trial is waived, must find the degree of the crime ... of which he is guilty. Upon the failure of the jury or the court to so determine, the degree of the crime ... of which the defendant is guilty, shall be deemed to be of the lesser degree."
(1) Petitioner contends that by operation of either of these two sections, his crime should be deemed second degree murder, and his insanity commitment should be corrected so to reflect. The Attorney General argues that both sections apply only to criminal cases with pleas of guilty or findings of guilt. He asserts that in 1969, before In re Moye, supra, 22 Cal.3d 457, was decided, there was no reason for the court to determine the degree of an offense in an insanity commitment; therefore, it is improper to say that the court "failed" to set the degree as contemplated by Penal Code sections 1157 and 1192. He interprets Moye as permitting the board to set petitioner's "maximum term" as the maximum for first degree murder.
*531 Penal Code section 1192 has no application here. "[B]y its own language, [it] purports to be applicable only when the court has in fact imposed a sentence...." (People v. Flores (1974) 12 Cal.3d 85, 94 [115 Cal. Rptr. 225, 524 P.2d 353]), a situation not present here. By contrast, the wording of Penal Code section 1157 is not linked to the court passing sentence. As noted by the Attorney General, on its face it applies only to convictions for crimes, but a statement in In re Eric J. (1979) 25 Cal.3d 522, 529 [159 Cal. Rptr. 317, 601 P.2d 549], suggests it may not be limited to adult criminal proceedings. Thus, it is at least potentially applicable here.
In In re Eric J., the minor was made a ward of the court when found to have committed a burglary. He had not been "convicted of a crime," but in describing the events, the Eric J. court stated: "Because the court failed to find the degree of the offense, it is deemed to be of the second degree. (Pen. Code, § 1157.)" (In re Eric J., supra, 25 Cal.3d at p. 529.)
Eric J. is distinguishable. There, the juvenile court was required by Welfare and Institutions Code section 726 to specify the maximum term of confinement based upon the maximum period an adult defendant could serve if convicted of the offenses which caused the juvenile's wardship. Here, at the time of petitioner's commitment there was no obligation imposed upon the court to determine the degree of the crime. We conclude that there was no "failure" by the court to determine degree because there was no cause to determine it. Thus, neither Penal Code section 1157 nor section 1192 applies.

(2) Should the trial court or the Board of Prison Terms be permitted to conduct a hearing to determine the degree of the crime?

In advising the board how to proceed in cases like this one, in March of 1979, opinion No. CR 79/11 I.L., the Attorney General concluded not only that Penal Code section 1192 should not fix the crime of an ISL inmate at the lower degree, but also that when In re Moye, supra, 22 Cal.3d 457, authorized use of the "maximum term," it meant that the board should set at the higher degree unless the pleadings or judgments compelled setting at the lower degree. The Attorney General concluded that entry of a single plea of not guilty by reason of insanity to an offense pleaded generally, but potentially divisible into degrees, was a complete admission of the offense of the higher degree. It is apparent from review of the board's term computation in this case that it automatically set the term as that for the higher degree "based on Attorney General's opinion, CR 79/11 I.L."
We conclude that the Attorney General's advice to the board violates the spirit of In re Moye, supra, 22 Cal.3d 457. Moye is easy to apply where there is no ambiguity in the crime for which the defendant was committed. It is not so *532 easy to apply in a situation such as the one presented here. However, nothing in Moye's reference to the "maximum term" for the underlying offense suggested that a person factually guilty of only second degree murder would receive the maximum term for first degree murder. Nor was there a suggestion that a presumption of first degree would apply where the degree of murder was not charged or found. Had petitioner been found sane, the court would have been required to determine the degree. (People v. Jennings (1958) 158 Cal. App.2d 159, 164 [322 P.2d 19]; Pen. Code, § 1192.) The fact that he was found insane and degree was not determined cannot justify commitment for longer than the underlying facts would justify.
Based on the foregoing analysis, it is our intention to direct the detaining authority to amend its commitment records in petitioner's case. We must now consider what further steps may be taken by the court and/or the board to establish or extend petitioner's commitment term.
At present, the degree of petitioner's crime is undetermined. We have considered the possibility that in "serious offender" proceedings brought under Penal Code section 1026.5, subdivision (a)(2), the Board of Prison Terms might be permitted to take evidence and establish the degree of petitioner's underlying offense. However, both the wording of the statute and considerations of due process counsel against such a factual determination being left to the board.
Penal Code section 1026.5, subdivision (a)(2), provides that once the board has initially fixed a defendant's term based on the commitment offenses, "... if at least two of the members of the board after reviewing the person's file determine that a longer term should be imposed for the reasons specified in [Penal Code] Section 1170.2, a longer term may be imposed ..." after a hearing.
Aside from the procedural question of whether the 90-day time limit for such extension hearing would have run (cf. In re Caudillo (1980) 26 Cal.3d 623 [164 Cal. Rptr. 692, 610 P.2d 1021]; In re Skief (1981) 120 Cal. App.3d 1040 [175 Cal. Rptr. 206]; In re Schaefer (1981) 116 Cal. App.3d 588 [172 Cal. Rptr. 335]), there is reason to doubt that Penal Code section 1026.5, subdivision (a)(2), authorizes the board to make a determination of the degree of a crime where the court has failed to act. The extended term hearing may be held only for the "reasons specified in Section 1170.2" of the Penal Code (see fn. 1), none of which involve failure to determine the degree of a crime. Absent explicit legislative instructions, we are unwilling to give to the board such a weighty responsibility.
*533 Had petitioner been found sane at the time of the crime, the trial court would have been required to determine the degree of the crime. (People v. Jennings, supra, 158 Cal. App.2d 159, 164.) Had his crime been committed on or after July 1, 1977, the court would have been required to determine the degree because it would have been required to state in the commitment order the maximum term of commitment. (Pen. Code, § 1026.5, subd. (a)(1).) We conclude that if the prosecutor wishes petitioner's insanity commitment to be based upon the maximum term for first degree murder, it must seek and obtain a similar determination from the trial court. If the prosecutor declines to seek a setting of degree, or fails to obtain a first degree determination, petitioner's maximum term of commitment must be reset at the term for second degree murder.
We fully appreciate the possible difficulties a prosecutor may encounter in attempting to prove the degree of a 14-year-old crime. For that reason, we will not require the prosecutor to make his or her decision immediately. However, if within 60 days of the finality of this decision the prosecutor has not set a hearing date for the determination of degree, the state hospital and the board must reset petitioner's term at the term for second degree murder.
(2) If the term is reset at second degree, petitioner will apparently be entitled to release unless a two-year extension is obtained under Penal Code section 1026.5, subdivision (b)(1). Petitioner argues that the deadline for seeking such an extension has long since passed because the hearing should have been sought when the decision was rendered in In re Moye, supra, 22 Cal.3d 457. We conclude, as we did under analogous facts in In re Skief, supra, 120 Cal. App.3d 1040, that the triggering event for an extension hearing is not a Supreme Court opinion entitling a defendant to relief, but the resetting of the defendant's term. Only then does the incentive to seek an extension arise.
By its terms, Penal Code section 1026.5, subdivision (b)(2), requires that a petition for a two-year extension be filed at least 90 days before the term expires. We have held in Johns v. Superior Court (1981) 119 Cal. App.3d 577 [175 Cal. Rptr. 443] that the period is not jurisdictional. Where, as here, the expiration of the term is caused by the term being reset, it would be unreasonable to require compliance with the 90-day requirement.[2] Instead, we conclude that if petitioner's term is reset for the maximum term for second degree murder, *534 and that term has expired, the petition for an extension under Penal Code section 1026.5, subdivision (b)(2), may be filed at any time up to and including 30 days after the term has been reset. The hearing on the petition may then be held at any time within 30 days after the petition has been filed.
Petitioner filed this petition as a petition for writ of mandate. However, it subsequently became apparent to the court that relief, if warranted, would come in the form of an order against the detaining authority. Therefore, we also issued an order to show cause re habeas corpus against the detaining authority. We treat the petition as a petition for writ of habeas corpus and grant partial habeas corpus relief. The alternative writ of mandate is discharged.
We do not order petitioner's immediate release from custody. However, the director of Atascadero State Hospital is directed to amend petitioner's records to show that instead of a maximum term of life imprisonment, petitioner's maximum term is presently undecided. If within 60 days from the finality of this opinion the prosecutor has not moved to set the degree and so advised the director, the director (in conjunction with the board) shall reset petitioner's maximum at the maximum for second degree murder.
White, P.J., and Barry-Deal, J., concurred.
A petition for a rehearing was denied March 25, 1983, and petitioner's application for a hearing by the Supreme Court was denied May 4, 1983.
NOTES
[1]  Reference to the "reasons specified in [Penal Code] Section 1170.2" apparently directs attention to the portion of subdivision (b) which states: "... the Board of Prison Terms shall establish the prisoner's parole date, subject to subdivision (d), on the date calculated under subdivision (a) unless at least two of the members of the Board of Prison Terms after reviewing the prisoner's file, determine that due to the number of crimes of which the prisoner was convicted, or due to the number of prior convictions suffered by the prisoner, or due to the fact that the prisoner was armed with a deadly weapon when the crime was committed, or used a deadly weapon during the commission of the crime, or inflicted or attempted to inflict great bodily injury on the victim of the crime, the prisoner should serve a term longer than that calculated in subdivision (a), in which event the prisoner shall be entitled to a hearing before a panel consisting of at least two members of the Board of Prison Terms as provided for in [Penal Code] Section 3041.5." (Italics added.)
[2]  We recognize that People v. Pacini (1981) 120 Cal. App.3d 877, 891 [174 Cal. Rptr. 820], and People v. Hill (1982) 134 Cal. App.3d 1055 [185 Cal. Rptr. 64], take the position that a petition for an extension under Penal Code section 1026.5, subdivision (b), must be filed before expiration of the term. However, neither case involved the resetting of a term after passage of the reset release date. Were we to conclude that the prosecution could not seek an extension if the term is reset at the term for second degree murder, we would be encouraging patients to delay any challenges to term setting until expiration of their "correct" terms, in order to foreclose the possibility of extension petitions. This thought provides us with ample cause to distinguish Pacini and Hill.
