
98 Cal.Rptr.2d 543 (2000)
82 Cal.App.4th 837
The PEOPLE, Plaintiff and Appellant,
v.
Herminia MATELSKI et al. Defendants and Respondents.
No. E025259.
Court of Appeal, Fourth District, Division Two.
July 31, 2000.
Rehearing Denied August 24, 2000.
Review Denied November 15, 2000.[*]
*544 Dennis L. Stout, District Attorney, Grover D. Merritt and Reza Sadeghi, Deputy District Attorneys, for Plaintiff and Appellant.
Andrew E. Rubin, Santa Monica, under appointment by the Court of Appeal, for Defendant and Respondent Herminia Matelski.
*545 Susan S. Bauguess, Running Springs, under appointment by the Court of Appeal, for Defendant and Respondent Raymond Matelski.

OPINION
HOLLENHORST, Acting P.J.
The People appeal denial of a motion to reinstate a criminal complaint under Penal Code section 871.5.[1] (§ 1238, subd. (a)(9).) The People contend that section 871.5 allows a motion for reinstatement when the superior court determines the magistrate erred in granting a suppression motion under section 1538.5. On the merits, the People contend the magistrate erred in finding that the officers acted unreasonably in detaining defendants to determine if they were convicted felons. The People argue the officer's actions were reasonable because defendants were visiting a probationer who was subject to a probation term that prohibited him from associating with convicted felons. The People also contend that the officers acted reasonably in arresting defendants on outstanding warrants, and in searching them for contraband. The officers found drugs in Herminia Matelski's purse, and those drugs were the subject of the suppression motion.
Defendants argue their detention was improper because there was no suggestion they were engaged in suspicious activity. Accordingly, they argue that the magistrate properly granted the suppression motion, and the superior court properly denied the motion to reinstate the charges.

FACTS
Officer Henry testified at the suppression hearing that he went with two other officers to a home in Twentynine Palms on September 8, 1998. The officers went to the home to conduct a probation search of a person named Michael Mitchell. The search was prompted by the fact that the probationer had failed a drug test.
As the officers arrived at the home, they saw defendants walking out the front door. One of the officers ordered defendants to "Come over here." The officers explained to defendants that a condition of Mr. Mitchell's parole prevented him from associating with persons who were convicted felons. The officer asked defendants for their names and dates of birth in order to determine if they were convicted felons. The information was given to the police dispatcher to check for warrants and criminal history. Both defendants had outstanding arrest warrants. Both were arrested and searched. Methamphetamine and two marijuana pipes were found in Herminia Matelski's purse. Each defendant told the officers that the methamphetamine belonged to Mr. Matelski.
Defendants were each charged with a violation of Health and Safety Code section 11377, subdivision (a), possession of a controlled substance.

THE SUPPRESSION MOTION
Defendants' suppression motion was based on the argument that defendants were not engaged in any criminal activity when they were detained, and the officers had no facts indicating even a suspicion of criminal activity. The People responded that it was reasonable to detain defendants to determine if they were convicted felons because, if they were, the parolee would have been in violation of his parole conditions in associating with them.
The magistrate, Judge Swift, applied the standard articulated in People v. Souza (1994) 9 Cal.4th 224, 36 Cal.Rptr.2d 569, 885 P.2d 982. In that case, our Supreme Court held that a person's flight at the sight of an officer or a marked police car "ordinarily is behavior that police may *546 legitimately regard as suspicious, and therefore also can be a key factor in establishing reasonable cause to detain in a particular case."[2] (9 Cal.4th at p. 227, 36 Cal.Rptr.2d 569, 885 P.2d 982.) Our Supreme Court reviewed the United States Supreme Court cases and found them to establish the general principle that "[a] detention is reasonable under the Fourth Amendment when the detaining officer can point to specific articulable facts that, considered in light of the totality of the circumstances, provide some objective manifestation that the person detained may be involved in criminal activity." (Id. at p. 231, 36 Cal.Rptr.2d 569, 885 P.2d 982.) Since the magistrate found that there was no such "objective manifestation" here, the magistrate granted the suppression motion.
The People filed a motion to reinstate the complaint under section 871.5. Under that section a motion to reinstate may be granted only if a superior court judge finds, as a matter of law, that the magistrate erroneously dismissed the action. The trial court, Judge McGuire, denied the motion. The People appeal.

PROCEDURAL ISSUES
Defendant Herminia Matelski offers two procedural reasons for not reaching the merits of the People's claim. First, she contends that the People fail to state a claim for relief under section 871.5. Second, she argues the appeal should be dismissed because the basis of the magistrate's ruling dismissing the action was section 1538.5, a section not mentioned in section 871.5, subdivision (a) as a basis for a motion under that section.
We find no merit in these arguments. The first argument is based on the theory that the People are challenging the magistrate's findings, rather than the superior court ruling. However, the notice of appeal clearly states that the appeal is taken from the decision of the superior court pursuant to section 1238, subdivision (a)(9). The People's brief clearly attacks the decision of the superior court on grounds that it should have granted the motion because the magistrate erroneously dismissed the action as a matter of law. (§ 871.5, subd. (b).) The fact that the remainder of the brief focuses on the magistrate's decision in order to demonstrate that it is legally erroneous does not convert the appeal into a direct attack on the magistrate's decision. Simply put, if the magistrate's decision was legally wrong, the superior court's decision upholding it was equally wrong.
The second argument is based on the premise that the action was dismissed pursuant to section 1538.5, rather than section 1385, a section mentioned in section 871.5, subdivision (a). The basis for the argument is the contention that the hearings that were held on March 24,1999, and April 12, 1999, were not part of a preliminary hearing, but rather were hearings pursuant to a section 1538.5 motion to suppress. The assumption underlying this argument is that section 871.5 cannot be used to review the granting of a suppression motion under section 1538.5.
The record displays considerable confusion as to whether the March 24th and April 12th hearings were part of a preliminary hearing, a hearing on the suppression motion, or both. The record shows the following: On March 2, 1999, a pre-preliminary conference was held and the preliminary hearing was set for March 24, 1999. A second conference was held on March 23, 1999. The parties agreed that the preliminary hearing would be held the *547 next day, but also agreed that the section 1538.5 motions which had previously been filed would also be heard on the next day.[3]
The clerk's minute orders for March 24th characterizes the hearing as a preliminary hearing, but states that the officer testified in connection with the suppression motion. They further state that the suppression motion was set for April 12, 1999, and the hearing, presumably the preliminary hearing, was also continued to that date.
The April 12th clerk's minutes characterize the hearing as a hearing on the section 1538.5 motion, and states that the motion to suppress is granted. They then state that the preliminary hearing is vacated and "[o]n motion of Court, Count(s) 1 dismissed in the interest of justice." A dismissal in the interests of justice is a dismissal under section 1385, and section 1385 is listed in section 871.5, subdivision (a) as a dismissal which may be challenged under that section.
The reporter's transcript of the March 24th hearing characterizes it as a hearing pursuant to section 1538.5, although the court proceeded as if it was conducting a preliminary hearing. For example, counsel stipulated, for preliminary hearing purposes only, that the substances found were methamphetamine. At the close of the hearing, defendants were advised of their rights to a continuous preliminary hearing, and appropriate waivers were obtained. These factors indicate that a preliminary hearing was in progress. However, at the close of the officer's examination, the magistrate asked if counsel was finished on the section 1538.5 motion, and the court then heard arguments on the motion and continued the hearing to April 12th.
On April 12th, the reporter's transcript contains a lengthy statement of decision by the magistrate. It concludes with the statement: "[T]he motion is granted." The magistrate then asked the deputy district attorney if he was able to proceed without the evidence, and the deputy replied negatively. The court then said: "All right. The motion is granted, and the matter is dismissed." This colloquy is normally the type of exchange that would be used at the conclusion of a preliminary hearing in which the evidence was found to be insufficient to hold the defendants over for trial. As noted above, the clerk interpreted the latter statement as a dismissal in the interests of justice under section 1385.
The defendants' contention that the hearing was, on the suppression motion appears to be a better characterization of the confused proceedings, but that is not enough. It appears that the magistrate was so thoroughly confused that he handled the suppression motion as if it were a preliminary hearing and was unclear as to the basis for dismissal of the action. Since the basis for dismissal is crucial, defendants ask us to find that the section 871.5 motion was improper because section 1538.5 is not mentioned in the introductory language of section 871.5, subdivision (a). However, it is equally likely that the case was dismissed pursuant to section 871 or section 1385, sections that are listed in section 875.5, subdivision (a).
In any event, we find two cases cited by the People to be dispositive of the issue. In Vlick v. Superior Court (1982) 128 Cal. App.3d 992, 180 Cal.Rptr. 742, defendant filed a motion to suppress search warrants under section 1538.5. The motion was granted by the magistrate, who then dismissed the complaint under section 871. The prosecution then filed a motion to reinstate the complaint under section 871.5. The defendant claimed that the exclusive remedy was found in section *548 1538.5. The appellate court rejected the contention after examining the legislative history of section 871.5. It found that section 871.5 "reflects legislative consideration of a comprehensive method of disposing of issues of law upon which a magistrate's dismissal of a felony complaint is based which when used by the People precludes them from refiling.... Having thus limited the People's action in this regard the Legislature devised a method by which they could obtain speedy review by the superior court of a dismissal by the magistrate based upon a legal ruling." (Id. at p. 998, 180 Cal.Rptr. 742.) Accordingly, the court held that a dismissal under section 1538.5 could be reviewed by the superior court under section 871.5: "Having allowed the magistrate to dismiss a felony complaint which dismissal serves as an effective bar to further prosecution, the Legislature provided a means by which the People could obtain immediate review of a magistrate's dismissal if it was based on an issue of law decided by him in ruling on any motion properly before him." (Id. at p. 999,180 Cal.Rptr. 742.)
The holding of Vlick was subsequently codified by the enactment of section 1538.5. subdivision (j). That section provides: "If the property or evidence relates to a felony offense initiated by complaint and the defendant's motion for the return of the property or suppression of the evidence at the preliminary hearing is granted, and if the defendant is not held to answer at the preliminary hearing, the people may file a new complaint [or, in] the alternative, the people may move to reinstate the complaint, or those parts of the complaint for which the defendant was not held to answer, pursuant to Section 871.5." This was essentially the procedure followed here. We therefore find it was proper.
In People v. Salzman (1982) 131 Cal. App.3d 676, 182 Cal.Rptr. 748, the court squarely held that section 871.5 gives the superior court jurisdiction to review an order of a magistrate dismissing a felony complaint following the granting of a section 1538.5 motion to suppress evidence. (Salzman, supra, 131 Cal.App.3d at p. 679, 182 Cal.Rptr. 748.) Thus, assuming that the dismissal here was pursuant to the granting of the suppression motion, the procedure used here was proper, as was the appeal. (§§ 871.5, 1238, subd. (a)(9); see also People v. Superior Court (Feinstein) (1994) 29 Cal.App.4th 323, 34 Cal. Rptr.2d 503 [Magistrate's actions had the effect of a dismissal under section 871, and use of section 871.5 was proper]; People v. Slaughter (1984) 35 Cal.3d 629, 200 Cal. Rptr. 448, 677 P.2d 854 [standard of review for a ruling under section 871.5].)
Defendant Herminia Matelski also raises a procedural issue by contending that the People have not established that the superior court erred in denying the motion to reinstate the complaint. Since resolution of this issue turns on whether the superior court acted properly in finding that the magistrate did not act erroneously in dismissing the action, we turn to the merits of the claim.

DISCUSSION
Since the Constitution proscribes unreasonable searches and seizures, it is the job of the courts to determine reasonableness in individual cases. The magistrate found the officers' actions were unreasonable.[4] "Because `that issue is a question of law,' the appellate court is not bound by the substantial evidence standard in reviewing the trial court's decision thereon. Rather, we explained, in such review it is `the ultimate responsibility of the appellate court to measure the facts, as found by the trier, against the constitutional standard of reasonableness.' [Citation.] On that issue, in short, the appellate court exercises its independent judgment." *549 (People v. Leyba (1981) 29 Cal.3d 591, 597, 174 Cal.Rptr. 867, 629 P.2d 961, fn. omitted.)
As noted above, the magistrate relied on People v. Souza, supra, 9 Cal.4th 224, 36 Cal.Rptr.2d 569, 885 P.2d 982. The issue presented by the People is the extent to which Souza has been affected by the later Supreme Court case of People v. Glaser (1995) 11 Cal.4th 354, 45 Cal.Rptr.2d 425, 902 P.2d 729. The People also rely on Michigan v. Summers (1981) 452 U.S. 692, 101 S.Ct. 2587, 69 L.Ed.2d 340, a case cited extensively in Glaser and People v. Hannah (1996) 51 Cal.App.4th 1335, 59 Cal.Rptr.2d 806.
In Summers, officers executed a search warrant at a house. While doing so, they encountered defendant leaving the house. They requested his assistance in entering the home and detained him while they searched the premises. (Michigan v. Summers, supra, 452 U.S. 692, 693, 101 S.Ct. 2587, 69 L.Ed.2d 340.) After finding drugs in the house, and learning that defendant owned the house, he was arrested and searched. Drugs were found in his pocket. (Ibid.) Defendant moved to suppress the drugs found in his pocket. The Supreme Court focused on the issue of whether the initial detention outside the premises was proper. (Id. at p. 694, 101 S.Ct. 2587.) In other words, the issue was whether the officers had the authority to require defendant to reenter the house and remain there while they conducted the search.
First, the court noted that there was a prearrest "seizure" of defendant and it assumed the seizure was without probable cause. (Michigan v. Summers, supra, 452 U.S. 692, 696, 101 S.Ct. 2587, 69 L.Ed.2d 340.) After stating the importance of the probable cause standard, the court noted that "some seizures significantly less intrusive than an arrest have withstood scrutiny under the reasonableness standard embodied in the Fourth Amendment. In these cases the intrusion on the citizen's privacy `was so much less severe' than that involved in a traditional arrest that `the opposing interests in crime prevention and detection and in the police officer's safety' could support the seizure as reasonable. [Citation.]" (Id. at pp. 696-697, 101 S.Ct. 2587.) Conversely, the court noted several cases in which it held a detention was unreasonable in the absence of any articulable facts available to the officer. (Id. at p. 699, fn. 9, 101 S.Ct. 2587.) The court concluded: "These cases recognize that some seizures admittedly covered by the Fourth Amendment constitute such limited intrusions on the personal security of those detained and are justified by such substantial law enforcement interests that they may be made on less than probable cause, so long as police have an articulable basis for suspecting criminal activity." (Id. at p. 699, 101 S.Ct. 2587.) The applicability of this exception for limited intrusions that are justified by special law enforcement interests depends upon the character of the official intrusion and its justification. (Id. at p. 701,101 S.Ct. 2587.)
A significant factor in evaluating the character of the intrusion is that it was pursuant to a search warrant, i.e., a neutral magistrate had concluded that there was probable cause to believe that the law was being violated in the house. (Michigan v. Summers, supra, 452 U.S. 692, 701, 101 S.Ct. 2587, 69 L.Ed.2d 340.) The warrant thus provided an objective justification for the detention. (Id. at p. 703, 101 S.Ct. 2587.) Other significant factors in evaluating the justification are the legitimate law enforcement interest in preventing flight if contraband is found, and officer safety considerations. (Id. at p. 702, 101 S.Ct. 2587.) Emphasizing the value of obtaining a search or arrest warrant, the court held: "If the evidence that a citizen's residence is harboring contraband is sufficient to persuade a judicial officer that an invasion of the citizen's privacy is justified, it is constitutionally reasonable to require that citizen to remain while officers of the law execute a valid warrant to search his home. Thus, for Fourth *550 Amendment purposes, we hold that a warrant to search for contraband founded on probable cause implicitly carries with it the limited authority to detain the occupants of the premises while a proper search is conducted." (Id. at pp. 704-705, 101 S.Ct. 2587, fns. omitted.)
In Glaser, officers arrived at a private home to search it pursuant to a search warrant. Defendant arrived about 20 seconds ahead of the officers and was about to open the gate to the property when the officers arrived and detained him. (People v. Glaser, supra, 11 Cal.4th 354, 360, 45 Cal.Rptr.2d 425, 902 P.2d 729.) Our Supreme Court found that the initial detention was "justified by the need to determine defendant's identity and connection to the premises and to protect the officers' own safety." (Id. at p. 360, 45 Cal.Rptr.2d 425, 902 P.2d 729.) Applying the principles of Michigan v. Summers, supra, 452 U.S. 692, 101 S.Ct. 2587, 69 L.Ed.2d 340, and Terry v. Ohio, supra, 392 U.S. 1, 88 S.Ct. 1868, 20 L.Ed.2d 889, our Supreme Court tested the detention against the reasonableness standard by balancing "the extent of the intrusion against the government interests justifying it, looking in the final and dispositive portion of the analysis to the individualized and objective facts that made those interests applicable in the circumstances of the particular detention. [Citations.]" (Glaser, at p. 365, 45 Cal. Rptr.2d 425, 902 P.2d 729.) After applying this test, the court found "`specific and articulable facts which, taken together with rational inferences from those facts, reasonably warrant that intrusion.' [Citation.]" (Id. at p. 373, 45 Cal.Rptr.2d 425, 902 P.2d 729.) However, the court rejected the proposition that the mere presence of a person at a home which is being searched pursuant to a warrant is sufficient reason to justify a detention for the purposes of determining identification and connection to the searched premises. (Id. at pp. 373-374, 45 Cal.Rptr.2d 425, 902 P.2d 729.) The court then articulated some standards to guide courts and officers in search warrant situations: "The existence of a warrant to search a home for illegal drugs, the presence of an unknown person on the premises when police begin the search, and the officer's inability to immediately determine the person's identity and connection to the premises without effecting a detention, are specific and articulable facts that, on balance, reasonably warrant a detention limited to the time and means needed to resolve the questions of identity and occupancy and to protect the safety of those present while those questions are resolved." (Id. at pp. 374-375, 45 Cal.Rptr.2d 425, 902 P.2d 729.)
The People also rely on People v. Hannah, supra, 51 Cal.App.4th 1335, 59 Cal. Rptr.2d 806. In that case, officers serving an arrest warrant on a third person arrived at an apartment and told the occupants to remain seated. Based on defendant's dilated eyes, the officers suspected him of being under the influence, and they attempted to arrest him. After a struggle, they succeeded in doing so. (Id. at p. 1339, 59 Cal.Rptr.2d 806.) After discussing Summers and Glaser, the court applied a totality of the circumstances test and found the detention reasonable. With regard to the crucial distinguishing factor, the lack of a search warrant, the court said: "Defendant correctly points out that Summers, supra, and the other cases discussed, involved detention of an individual during the execution of a search warrant for contraband. By the same token, none of these cases require the existence of a search warrant for contraband as a prerequisite to finding the detention of an individual to be reasonable. The existence of a warrant is but one factor the courts consider when determining the governmental interest involved." (Id. at p. 1343, 59 Cal.Rptr.2d 806.) The court went on to hold, in terms we find dispositive, as follows: "Objectively, it is reasonable for a police officer who is in a residence attempting to execute an arrest warrant to determine who is present. This is true even when he does not reasonably believe any one of them is the subject of the arrest *551 warrant. If the police officer has received information the suspect he is attempting to arrest is in the residence, it is reasonable to conclude people inside may know the suspect and have information concerning where he might be found. Additionally, a reasonable police officer could be concerned the individuals in the residence not only know the suspect, but are either related to or friends with him. Therefore, it is reasonable to conclude the individuals may attempt to alert the suspect to the fact the police are there or might assist him in escaping. Consequently, there was a legitimate governmental interest in detaining defendant to determine who he was and if he had any information concerning the juvenile they were searching for, while the other officers searched the apartment. In addition, the detention was reasonably necessary to ensure defendant did not warn the juvenile or assist him in evading arrest." (Id. at pp. 1345-1346, 59 Cal. Rptr.2d 806.)
We agree with the People that the test to be applied is that stated in Glaser and Hannah, and that proper application of that test establishes that the detentions here were constitutionally reasonable. That is, "we balance the extent of the intrusion against the government interests justifying it, looking in the final and dispositive portion of the analysis to the individualized and objective facts that made those interests applicable in the circumstances of the particular detention. [Citations.]" (People v. Glaser, supra, 11 Cal.4th 354, 365, 45 Cal.Rptr.2d 425, 902 P.2d 729.)
The extent of the intrusion here was minimal. Although the People contend that there was no detention, we agree with the defendants and the magistrate that the defendants were detained. The officer testified that the probation officer instructed defendants to remain outside the home, and they were subsequently instructed to enter it. The officer believed the probation officer was giving an order to prevent defendants from leaving.
However, the detention was brief. Although the parties disagree as to the length of time, the officer testified that he explained the purpose of the contact for five or 10 minutes. He radioed the defendants' identification to the dispatcher and within five minutes was told that the defendants had outstanding warrants. At that point, he considered them to be under arrest and they would not have been allowed to leave. The total detention was fifteen minutes. As Glaser states: "While the length of the detention is only one circumstance, here its brevity weighs heavily in favor of a finding of reasonableness. (See United States v. Sharpe (1985) 470 U.S. 675, 686-688 [105 S.Ct. 1568, 84 L.Ed.2d 605] [20-minute investigative detention reasonable under circumstances].)" (People v. Glaser, supra, 11 Cal.4th 354, 367, 45 Cal.Rptr.2d 425, 902 P.2d 729.)
As in Glaser, there was no particular embarrassment or stigma attached to the detention because it was not viewed by the public. Although the detention occurred in the front yard, the home was in a remote area on a dirt road and there is no evidence that defendants were seen by others. "The embarrassment and stigma sometimes associated with a detention were thus reduced or eliminated. [Citation.]" (People v. Glaser, supra, 11 Cal.4th 354, 367, 45 Cal.Rptr.2d 425, 902 P.2d 729.)
The brief intrusion was also justified by the same governmental interests justifying the detention as those cited in Glaser: "the need to determine what connection defendant, who appeared to be more than a stranger or casual visitor, had to the premises, and by the related need to ensure officer safety and security at the site of a search for narcotics." (People v. Glaser, supra, 11 Cal.4th 354, 365, 45 Cal. Rptr.2d 425, 902 P.2d 729.)
While there was no need here to determine defendants' connection to the premises, there was a need to determine defendants' connection to the probationer *552 because the probationer was prohibited by his general terms of probation from consorting with convicted felons.
Although downplayed by defendants, there were also officer safety concerns here. The officer testified that Mr. Matelski was considerably larger than the officer, and was upset at being detained. The officer did not know whether the defendants were armed, and the People properly note that persons using or dealing in drugs are frequently armed. (People v. Glaser, supra, 11 Cal.4th 354, 367-368, 45 Cal.Rptr.2d 425, 902 P.2d 729.) It is no answer to say that the defendants' unhappiness would have been eliminated by allowing them to leave because of the possibility they could have armed themselves and returned, perhaps with others, to threaten the officers. Security demands that the persons in the home at the time of the officers' arrival remain there until the officers have completed their investigation.
Hannah's totality of the circumstances analysis also supports the detention here. First, Hannah confronts the obvious distinguishing factor that, in the present case, there was no search or arrest warrant. Thus, only officer discretion was involved here, because there was no independent judicial finding of probable cause for a search or arrest warrant. As Summers states: "Of prime importance in assessing the intrusion is the fact that the police had obtained a warrant to search respondent's house for contraband. A neutral and detached magistrate had found probable cause to believe that the law was being violated in that house and had authorized a substantial invasion of the privacy of the persons who resided there." (Michigan v. Summers, supra, 452 U.S. 692, 701, 101 S.Ct. 2587, 69 L.Ed.2d 340.)
"[N]one of these cases require the existence of a search warrant for contraband as a prerequisite to finding the detention of an individual to be reasonable. The existence of a warrant is but one factor the courts consider when determining the governmental interest involved. For example, we observe the police officer in Terry v. Ohio, supra, did not have a search or arrest warrant when he stopped and frisked Terry. [Citation.] However, the United States Supreme Court found the actions of the police officer reasonable under the totality of the circumstances." (People v. Hannah, supra, 51 Cal.App.4th 1335, 1343, 59 Cal.Rptr.2d 806.)
Hannah thus found the lack of a search warrant was not dispositive. (People v. Hannah, supra, 51 Cal.App.4th 1335, 1345, 59 Cal.Rptr.2d 806.) Here, the officers had neither an arrest nor a search warrant. However, they were not acting randomly. The officers were conducting a valid search of the home of a probationer who had failed a drug test. In order to obtain probation on general terms and conditions, a criminal defendant must waive his Fourth Amendment rights: "A probationer, unlike a parolee, consents to the waiver of his Fourth Amendment rights in exchange for the opportunity to avoid service of a state prison term. Probation is not a right, but a privilege." (People v. Bravo (1987) 43 Cal.3d 600, 608, 238 Cal. Rptr. 282, 738 P.2d 336.) Since the probationer waived his Fourth Amendment rights, the officers were properly able to enter the premises to search it without a warrant.
We emphasize that this was not a suspicionless intrusion (People v. Reyes (1998) 19 Cal.4th 743, 751, 80 Cal.Rptr.2d 734, 968 P.2d 445) or a case in which the officers were unaware of the probationer's status (In re Tyrell J. (1994) 8 Cal.4th 68, 32 Cal.Rptr.2d 33, 876 P.2d 519). Nor was this a parole search based on reasonable suspicion, as described in People v. Burgener (1986) 41 Cal.3d 505, 224 Cal.Rptr. 112, 714 P.2d 1251, overruled by Reyes, supra, 19 Cal.4th at page 756, 80 Cal. *553 Rptr.2d 734, 968 P.2d 445.[5] Instead, the officers were at the residence to enforce probation terms against Mr. Mitchell because he had flunked a drug test. They wanted to conduct a probation search in order to determine if Mr. Mitchell was possessing drugs or otherwise violating his probation terms.
Once properly on the premises, the officers were able to briefly detain other persons on the premises to determine their identity. We therefore conclude that the intrusion on defendants' privacy was minimal, the governmental interests stated above outweighed the brief intrusion on defendants' privacy, and that the lack of a search or arrest warrant was not dispositive. As Burgener held in the parole context: "The justification for exempting parole searches from the warrant requirement of the Fourth Amendment is that these searches are necessary for effective parole supervision. If a search is to have a parole supervision purpose therefore it must be based on information which leads the parole agent who conducts or authorizes the search to believe that the parolee has violated the law or another condition of his parole, or is planning to do so. Were this not so, a parole search would not only invade the parolee's reasonable expectation of privacy, but would unreasonably intrude into the privacy interests of persons with whom the parolee associates or resides. Inasmuch as authority to search the residence of a parolee extends to areas which are jointly controlled with other occupants of the residence [citations], the authority to search these premises necessarily portends a massive intrusion on the privacy interests of third persons solely because they reside with a parolee. [Citations.] A parole search must therefore be directly and closely related to parole supervision in order to avoid unreasonable invasion of the privacy interests of the parolee and those with whom he resides." (People v. Burgener, supra, 41 Cal.3d 505, 533-534, 224 Cal.Rptr. 112, 714 P.2d 1251, fn. omitted.)
Although there was some intrusion on the privacy interests of the Matelskis as a result of the probation search here, we find that such intrusion was minimal and not unreasonable in the light of the officer's duty to ascertain if Mr. Mitchell was violating the terms of his probation. The officers simply had no other way to enforce the probation term that Mr. Mitchell not associate with known felons unless they could identify his associates and determine whether they were known felons or not. They did so in a minimally intrusive manner, and we find that the intrusion did not violate the privacy rights of defendants. Thus, if we balance the privacy interests of the defendants, who were associating with the probationer, against the governmental interests in enforcing a valid term of probation, we find that the governmental interests outweighed the brief and minimally intrusive detention of the defendants for the purpose of learning their identity in order to determine if they were known felons.
Again, we emphasize that the officers were not acting randomly, but rather had specific articulable reasons for entering the home and detaining defendants. After ascertaining the identity of defendants and learning that they were the subject of outstanding warrants, the officers properly arrested them and discovered the contraband in Herminia Matelski's purse. Under these circumstances, the magistrate erred in granting the suppression motion and the trial court erred in refusing to grant the People's section 871.5 motion.

DISPOSITION
The superior court's refusal to grant the People's motion under section 871.5 was *554 erroneous. The superior court's order is reversed and it is directed to return the case to the magistrate with orders to resume the proceedings within 10 days, pursuant to section 871.5, subdivision (e).
RICHLI, J, concurs.
Dissenting Opinion of GAUT, J.
I respectfully dissent.
There is no dispute over the facts in this case. We therefore exercise our independent judgment to determine whether on the basis of those undisputed facts the detention and ultimate search of the Matelskis was reasonable under the Fourth Amendment. (People v. Glaser (1995) 11 Cal.4th 354, 362, 45 Cal.Rptr.2d 425, 902 P.2d 729.)
It is undisputed that the Matelskis were exiting the home of Michael Mitchell as officers arrived for a parole search of Mitchell's home. The officers did not have a search warrant, but needed none to search Mitchell's home under the terms of his parole. The officers detained the Matelskis not because of any concern for officer safety, or because they feared the Matelskis would alert Mitchell to their presence, or because of concern about flight, or because they believed the house belonged to the Matelskis. (People v. Glaser, supra, 11 Cal.4th at p. 365, 45 Cal. Rptr.2d 425, 902 P.2d 729.) The officers articulated no "... facts causing [them] to suspect that (1) some activity relating to crime has taken place or is occurring or about to occur, and (2) the [Matelskis were] ... involved in that activity." (People v. Leyba (1981) 29 Cal.3d 591, 597, 174 Cal.Rptr. 867, 629 P.2d 961.)
The officers testified they detained the Matelskis solely because they wanted to know whether the Matelskis were convicted felons, which would have violated a condition of Mitchell's parole prohibiting association with convicted felons. But there was no such restraint on the Matelskis. They were free to visit Mitchell. The officers therefore had no reasonable suspicion that a crime had occurred or was about to occur and that the Matelskis were involved in that crime.
In the Leyba case the Supreme Court indicated that not only must the officers entertain a suspicion that a crime has occurred or is occurring and that the party detained is involved in that activity, that subjective suspicion must be objectively reasonable. (People v. Leyba, supra, 29 Cal.3d at p. 597, 174 Cal.Rptr. 867, 629 P.2d 961.)
The majority argues that the intrusion upon the Matelskis was minor when balanced against the governmental interests justifying the detention. I disagree. In the Glaser case, the police had a search warrant for a private residence where illegal drugs or related items were allegedly located. The Supreme Court noted that if in the process of serving the warrant "police officers encounter on the premises a person whose identity and connection to the premises are unknown and cannot immediately be determined without detaining the person, the officers may constitutionally detain him or her for the period of time required and in the manner necessary to make those determinations and to protect the safety of all present during the detention. If the person is determined to be an occupant of the home to be searched, he or she may be detained ... for the duration of the search. [Citation.] If the person is determined not to be an occupant, further detention is proper only if justified by other specific, articulable facts connecting him or her to the criminal activity suspected to be occurring on the premises or establishing a danger to the officers if the person is released." (People v. Glaser, supra, 11 Cal.4th at p. 374, 45 Cal.Rptr.2d 425, 902 P.2d 729.)
None of the Glaser facts were present here. There was no search warrant. There was no evidence of illegal activity on the premises. The officers could have determined in seconds that the Matelskis were not residents of the home. The detention of the Matelskis was admittedly not for the purpose of officer safety. The situation was not unstable. There was no "`specific and articulable facts' that reasonably *555 warrant[ed] the intrusion on personal liberty and privacy." (People v. Glaser, supra, 11 Cal.4th at p. 374, 45 Cal.Rptr.2d 425, 902 P.2d 729.) Those facts support the trial court's legal conclusion which resulted in the suppression of the evidence found as a result of the search of the Matelskis. (See People v. Loudermilk (1987) 195 Cal.App.3d 996, 1001, 241 Cal.Rptr. 208.)
I would affirm the decision of the magistrate and the trial court to suppress the drugs discovered as a result of the detention.
NOTES
[*]   Kennard, J., dissented.
[1]  Unless otherwise indicated, all further statutory references are to the Penal Code.
[2]  In the recent case of Illinois v. Wardlow (2000) 528 U.S. 119, 120 S.Ct. 673, 145 L.Ed.2d 570, the Supreme Court held that defendant's flight when he saw officers was a factor to be considered in determining reasonable suspicion for a brief stop pursuant to Terry v. Ohio (1968) 392 U.S. 1, 88 S.Ct. 1868, 20 L.Ed.2d 889. (See also Wyoming v. Houghton (1999) 526 U.S. 295, 119 S.Ct. 1297, 143 L.Ed.2d 408, which approved the search of a car passenger's purse during a routine traffic stop.)
[3]  Section 1538.5 motions were filed on October 6, 1998 by Mr. Matelski's counsel and on October 8, 1998, by Herminia Matelski's counsel. Opposition was filed on November 13, 1998, and the motions were set for hearing on November 18, 1998. The earlier action was dismissed, apparently because the officer was unavailable to testify, and the case was refiled on January 29, 1999.
[4]  The trial court merely denied the motion without comment. We thus do not have the benefit of its analysis of the issue.
[5]  Issues relating to the continued validity of Tyrell J., Reyes, and Burgener are presently pending before the Supreme Court in the cases of People v. Moss, review granted June 28, 2000 (S087478) and People v. Robles,* review granted October 14, 1998 (S072243).

* Reporter's Note: For Supreme Court opinion, see 23 Cal.4th 789, 97 Cal.Rptr.2d 914, 3 P.3d 311.
