#### The People of the State of New York ex rel. Lee Schlesinger, Appellant, v. Edward M. Fay, as Warden of Green Haven Prison, Respondent.

— In a habeas corpus proceeding, relator appeals from an order of the Supreme Court, Dutchess County, entered December 7, 1962, after a hearing, which dismissed the writ and remanded him to the custody of respondent. Order affirmed. On December 15, 1959 relator was convicted, after trial in the Court of General Sessions, of the crime of murder in the second degree and was sentenced to a term of 20 years to life. The sentence was a mandatory sentence for the crime of murder in the second degree (Penal Law, § 1048). The judgment of conviction was affirmed *(People*v. *Schlesmger,*14 A D 2d 760, affd. 11 N Y 2d 806). Section 335-b of the Code of Criminal Procedure became a law on April 1, 1959, effective as of September 1, 1959 (L. 1959, eh. 219). It was amended by chapter 578 of the Laws of 1963, effective September 1, 1963, so as to limit the need for the statutory warning to eases where guilty pleas were accepted by the court; but the amendment may be disregarded on this appeal. As enacted in 1959, section 335-b provided that: “where the crime or offense with which defendant is charged * *. * is one for which a different or additional punishment is prescribed or expressly authorized by reason of the fact that the defendant has previously been convicted of a crime or offense, the court upon the arraignment of the defendant and before accepting a plea must inform the defendant that if he has previously been so convicted that fact may be established after his conviction or plea of guilty in the action before the court and he will be subject to such different or additional punishment.” Relator’s trial took place and the judgment of conviction was rendered after the effective date of the statute enacted in 1959, but he was arraigned and his plea of not guilty was entered before its effective date. Relator attempts to vitiate the judgment of conviction on the alleged ground that there was a failure to comply with the statute (cf. *People ex rel. McIntosh*v. *Fay,*18 A D 2d 175). The statute requires the warning to be given whether or not a defendant is represented by counsel and whether he pleads guilty or not guilty *(People*v. *Schulman,*13 A D 2d 441). But, in our opinion, if a defendant: (1) pleads not guilty; (2) is represented by counsel at the time of the entry of the plea; (3) is represented by counsel during the trial; and (4) fails to show that he was prejudiced by the court’s failure to give the warning prescribed by the statute, the judgment of conviction may not be set aside because the court failed to give the statutory warning (cf. *Matter of Astman*v. *Kelly,*2 N Y 2d 567). Moreover, assuming *arguendo*that on and after September 1, 1959 the mere failure of a court to give the warning prescribed by the statute before it accepts a not guilty plea vitiates the judgment rendered after trial, it is our opinion that the statute is not to be applied retroactively in a case where the trial was held after the *633effective date of the statute but the defendant was arraigned and entered a not guilty plea before the effective date. Ughetta, Acting P. J., Christ, Brennan, Hill and Hopkins, JJ., concur.