
264 Cal.App.2d 679 (1968)
THE PEOPLE, Plaintiff and Respondent,
v.
JOE MARTINEZ, Defendant and Appellant.
Crim. No. 12823. 
California Court of Appeals. Second Dist., Div. One.  
Aug. 5, 1968.
 G. Marc Von Burger, under appointment by the Court of Appeal, for Defendant and Appellant.
 Thomas C. Lynch, Attorney General, William E. James, Assistant Attorney General, and Thomas E. Warriner, Deputy Attorney General, for Plaintiff and Respondent.
 LILLIE, J.
 Defendant was found guilty of possession of heroin ( 11500, Health & Saf. Code) and sentenced to the state prison. He appeals from the judgment. *680
 On August 12, 1965, Officer Barbarick received from the parole office, Department of Corrections, a teletype notice advising that defendant was wanted for a violation of parole ( 3056, Pen. Code) and giving his description. Officer Barbarick talked with Parole Officer Damerell, special agent, Department of Corrections, concerning defendant and later was furnished with defendant's address and photograph; he then went to the apartment at that address and showed the photograph to the manager who identified defendant as a tenant living there with a woman. Thereafter, he and other officers, including Parole Officer Damerell, kept the premises under surveillance. Around 9 p.m. on October 26, 1966, Officer Barbarick in the company of Officers Walsh, Trotsky and Olson passed defendant's apartment and for the first time saw a light in it; immediately he called Parole Officer Damerell who told him he would be there shortly and to go ahead and arrest defendant. Thus Officer Barbarick and two officers went to the front and Officer Olson to the kitchen window; as they knocked on the front door and identified themselves as police officers, Officer Olson who was at the kitchen window, shouted, "He's coming through the window." They then forced the front door open and Officer Barbarick saw defendant running from the kitchen toward the bathroom "hollering, 'Swallow it, swallow it,' " and close the door. They forced open the bathroom door but defendant had escaped through the bathroom window. In the living room Officer Trotsky had Conrad Garcia in custody; Garcia claimed to be a visitor. Officer Barbarick searched the apartment and found a red balloon containing heroin in the pocket of a man's shirt hanging in the closet; narcotics paraphernalia was also found in the apartment. One of the spoons contined a heroin residue.
 [1] The sole issue is the legality of the entry and search of the premises and seizure of the heroin. Relying on People v. Rosales, 68 Cal.2d 299 [66 Cal.Rptr. 1, 437 P.2d 489], appellant contends that the entry was unlawful in that the officers failed to demand entrance and explain the purpose for which admittance was desired ( 844, Pen. Code)  [fn. 1] and he was neither present nor under arrest at the time of the search, thus the seizure of the heroin was unlawful. *681
 In People v. Rosales, 68 Cal.2d 299 [66 Cal.Rptr. 1, 437 P.2d 489], as in the case at bench, the officers went to defendant's apartment for the purpose of arresting him for parole violation; two went to the front door, the others to the rear. Before entering the premises one of the officers saw defendant through the front screen door sitting on a couch with his back to the door. The officers then entered without announcing their purpose or demanding entry. The court held that noncompliance with section 844 was not excused--the officers observed no suspicious activity and there was no evidence that defendant might escape. This is quite a different situation than the instant one. Here the officers knocked on the door and identified themselves as police officers, but as they did so they were warned by the officer who had gone to the kitchen window that defendant was going through a window. It was then they entered and defendant indeed was in the process of making his escape, and in fact accomplished it by way of a window in the bathroom. It is clear that at the time the officers entered, the facts known to them were sufficient to support their good faith belief that compliance with section 844 would have frustrated defendant's arrest. This belief was in fact confirmed by subsequent events.
 "Noncompliance with section 844 may nevertheless be excused when the officer acts on a reasonable and good faith belief that compliance would increase his peril, frustrate an arrest, or permit the destruction of evidence. Such a belief, however, must be based on the facts of the particular case." (People v. Rosales, supra, 68 Cal.2d 299, 305 [66 Cal.Rptr. 1, 437 P.2d 489]; People v. Gastelo, 67 Cal.2d 586, 587 [63 Cal.Rptr. 10, 432 P.2d 706]; People v. Carrillo, 64 Cal.2d 387, 391 [50 Cal.Rptr. 185, 412 P.2d 377]; People v. Maddox, 46 Cal.2d 301, 306 [294 P.2d 6].)people v. Maddox, 46 Cal.2d 301, 306 [294 P.2d 6], was relied upon in People v. Gastelo, 67 Cal.2d 586 [63 Cal.Rptr. 10, 432 P.2d 706]: "In Maddox, we held that compliance with the the substantially identical notice requirements of Penal Code section 844 for making arrests was excused, if the facts known to the officer before his entry were sufficient to support his good faith belief that compliance would have increased his peril or frustrated the arrest." (P. 587.)
 Under the circumstances here, noncompliance with the statute does not compel the exclusion of the heroin seized in the search of defendant's apartment. (People v. Hammond, 54 Cal.2d 846, 854 [9 Cal.Rptr. 233, 357 P.2d 289]; People v. *682 Maddox, 46 Cal.2d 301, 306-307 [294 P.2d 6].) "When there is reasonable cause to make an arrest, and the facts known to the arresting officers before crossing the threshold are not inconsistent with the good faith belief on their part that compliance with the formal requirements of section 844, Penal Code, is excused, a failure to comply therewith does not invalidate the search and seizure made as incident to the ensuing arrest. The evidence in this case brings it within the foregoing rule." (People v. Wolfe, 257 Cal.App.2d 420, 429 [64 Cal.Rptr. 855].)
 While it is true that defendant was not present when the search was made, he having escaped through the window, and that he was apprehended and arrested after the search was completed, the search is nonetheless lawful. "Cases in this state have held that if before making a search and seizure officers are justified in making an arrest it is immaterial that the search and seizure preceded rather than followed the arrest. (E.g., People v. Torres, supra (1961) 56 Cal.2d 864, 866 [17 Cal.Rptr. 495, 366 P.2d 823]; Willson v. Superior Court (1956) 46 Cal.2d 291, 294 [294 P.2d 36]; People v. Simon (1955) 45 Cal.2d 645, 648-649 [290 P.2d 531].)" (People v. Cockrell, 63 Cal.2d 659, 666 [47 Cal.Rptr. 788, 408 P.2d 116]; People v. Ingle, 53 Cal.2d 407, 413 [2 Cal.Rptr. 14, 348 P.2d 577]; People v. Boyles, 45 Cal.2d 652, 655 [290 P.2d 535].) Moreover, the evidence shows that the officers went to defendant's apartment to arrest him for a parole violation and were acting as agents of the Department of Corrections. A parole officer needs neither a search warrant nor consent of a parolee to search his premises. (People v. Thompson, 252 Cal.App.2d 76, 84- 85 [60 Cal.Rptr. 203].)
 The judgment is affirmed.
 Wood, P. J., and Fourt, J., concurred.
NOTES
[fn. 1]  1. "To make an arrest, ... a peace officer, may break open the door or window of the house in which the person to be arrested is, or in which they have reasonable grounds for believing him to be, after having demanded admittance and explained the purpose for which admittance is desired."
