
193 Ill. App.3d 754 (1990)
550 N.E.2d 702
THE PEOPLE OF THE STATE OF ILLINOIS, Plaintiff-Appellee,
v.
SCOTT C. SEEHAUSEN, Defendant-Appellant.
No. 2-88-0721.
Illinois Appellate Court  Second District.
Opinion filed February 9, 1990.
*755 *756 John R. Krupa and Paul S. Braun, both of Krupa & Braun, Chartered, of Flossmoor, for appellant.
James E. Ryan, State's Attorney, of Wheaton (William L. Browers and *757 Mary Beth Burns, both of State's Attorneys Appellate Prosecutor's Office, of counsel), for the People.
Judgment affirmed.
PRESIDING JUSTICE UNVERZAGT delivered the opinion of the court:
Defendant, Scott C. Seehausen, was charged by indictment with the offenses of attempted murder (Ill. Rev. Stat. 1985, ch. 38, par. 8-4(a)), solicitation to commit murder (Ill. Rev. Stat. 1985, ch. 38, par. 8-1(a)), and conspiracy to commit murder (Ill. Rev. Stat. 1985, ch. 38, par. 8-2(a)). Following a jury trial, defendant was convicted of attempted murder and solicitation to commit murder and was subsequently sentenced to 16 years' imprisonment. Defendant filed a post-trial motion which was denied. This appeal followed.
On appeal, defendant argues: (1) that the grand jury's indictment of him was improperly obtained; (2) that the trial court erred in failing to suppress the "fruits" of the eavesdropping authorization; and (3) that the trial court erred in failing to charge the jury with Illinois Pattern Jury Instructions, Criminal, No. 3.17 (2d ed. 1981) (hereinafter IPI Criminal 2d), dealing with accomplice testimony.
The following facts are material to our decision. In April 1986, defendant obtained $27,500 from Stanley Fry on the pretense that defendant would invest the money in stock. But, in fact, defendant misappropriated the funds. In early June 1986, Fry began pressuring defendant for the return of his money. As a consequence, defendant hired Jeffrey Witzke to deliver to Fry on June 12, 1986, a sandwich tainted with sodium cyanide. Defendant offered to pay Witzke $50,000 for this act. Defendant told Witzke that he wanted to murder Fry because Fry had amassed a fortune with money defendant had given him and, yet, Fry had never shared with defendant any of the money Fry had made with defendant's funds.
On June 11, 1986, Fry received a visit at his office from Witzke. Witzke told Fry about defendant's plan to kill him. Fry contacted the Westmont police department, and he and Witzke subsequently met with Detective Musial and Captain Brindac of that department. Witzke related to Musial defendant's plans to kill Fry. Witzke then gave Musial tapes Witzke had made on June 11 of his conversations with defendant.
On the morning of June 12, Witzke contacted Detective Musial to tell him that defendant planned to kill Fry that evening. Later that morning, a circuit judge granted Musial's petition for authorization of the use of eavesdropping devices to record conversations between defendant and Fry and between defendant and Witzke. Both Fry and *758 Witzke consented to the use of the eavesdropping devices. A small recorder was put on the telephone in Fry's office. Witzke was to carry a small tape recorder in his jacket pocket.
It was defendant's defense at trial that Witzke had purchased the cyanide and had tainted the sandwiches with the poison. Additionally, the defense tried to show that defendant's original plan was to use methol propanol, a drug, instead of cyanide merely to knock Fry out for a few hours. The evidence showed that defendant did on one occasion discuss with Witzke using methol propanol on a sandwich but that Witzke later learned it was cyanide defendant intended to place on the sandwich. Also, the tape recordings which were made of the conversations occurring between Witzke and defendant on June 12 and which were played to the jury at trial indicated it was defendant who placed the cyanide on the sandwich intended for Fry and that it was defendant's intent to kill Fry. At trial, forensic scientist Paul Titus, who performed tests on the sandwich in question, testified that the sandwich contained a lethal dose of cyanide.
On the evening of June 12, the sandwich laced with cyanide was delivered to Fry at his office by Witzke. Pursuant to the direction of an officer stationed inside Fry's office, Witzke used Fry's telephone to call defendant on defendant's car phone. Witzke told defendant that Fry had eaten the sandwich and collapsed but that he was still breathing. Defendant then instructed Witzke to hold Fry's nose and place his hand over Fry's mouth until Fry was no longer breathing. This conversation, which was recorded via the small recorder placed on Fry's telephone, was also played to the jury. Shortly after this phone conversation, defendant was arrested in his car.
Subsequently, a three-count indictment was obtained against defendant for attempted murder, solicitation to commit murder, and conspiracy to commit murder. The charge of conspiracy to commit murder was dismissed prior to trial.
After the case had proceeded to trial, the jury instruction conference was held. During that conference, defendant tendered IPI Criminal 2d No. 3.17, dealing with accomplice testimony. The trial court refused to charge the jury with the instruction, ruling that Witzke was not an accomplice under the terms of the instruction because he was not "involved in the commission of a crime."
Following trial, the jury returned a verdict of guilty to the charges of solicitation to commit murder and attempted murder. Later, the trial judge sentenced defendant to 16 years of imprisonment. Defendant then filed this appeal, claiming three contentions of error.
Defendant first argues that the grand jury's indictment of him was *759 improperly obtained because it was influenced by the prosecuting attorney's improper comments in unsworn testimony. Defendant maintains that the prosecutor's comments were prejudicial and constituted the sole means by which grand jurors' questions concerning critical areas of the investigation were answered. Therefore, the defendant asserts, the trial court erred in denying defendant's motion to dismiss the indictment. The State counters that the comments of which defendant complains are taken out of context, were not improper, and were made to advise the grand jury, which is the prosecutor's function.
 1 Although, generally, a defendant may not challenge the validity of an indictment returned by a legally constituted grand jury, courts have carved out certain exceptions to this rule. (People v. Rodgers (1982), 92 Ill.2d 283, 287.) One of these exceptions permits defendants to challenge indictments where there are clear allegations of prosecutorial misconduct. (People v. Linzy (1979), 78 Ill.2d 106, 109.) However, to support a dismissal of an indictment, the defendant must show that the prosecutorial misconduct complained of resulted in actual and substantial prejudice to the defendant. People v. Boyle (1987), 161 Ill. App.3d 1054, 1065; People v. Martin-Trigona (1982), 111 Ill. App.3d 718, 726.
In both his brief and reply brief, defendant refers to certain statements made by the prosecutor during the grand jury proceeding. Defendant claims that these statements were incorrect and misleading, were not made by the prosecutor in his role as advisor, and, therefore, were unsworn testimony. We disagree with defendant for several reasons. First, defendant has distorted the statements of which he complains by presenting them out of context. Second, the statements were made during or after Detective Musial's testimony and constituted either answers to jurors' questions or comments aimed at aiding and advising the jurors in their investigation. Third, the factual information contained in the prosecutor's statements had already, for the most part, been placed before the grand jury by Detective Musial during his testimony.
Defendant's reliance on United States v. Gold (N.D. Ill. 1979), 470 F. Supp. 1336, to argue that a prosecutor cannot submit unsworn testimony before the grand jury while also acting as the agent of the prosecuting authority is totally misplaced. In Gold, the prosecutorial misconduct, which resulted in a dismissal of defendants' indictment, was based on a conflict of interest. A staff attorney from the Environmental Protection Agency (EPA) acted as a special attorney for the justice department in a criminal investigation while also working on the EPA's administrative proceeding against the same defendants. In *760 these capacities, he appeared both as a prosecutor and as a witness before the grand jury although he never obtained permission from the justice department for his dual roles. The district court determined that in attempting to perform these dual roles, the attorney was a lawyer laboring under a conflict of interest and, therefore, a person who was unauthorized to be in the grand jury room. A dismissal of the indictment was required.
 2 No such role reversal occurred in the instant case. The prosecutor did not act as both prosecutor and witness before the grand jury but rather as prosecutor and advisor, a function of his role as prosecutor. (People v. Linzy, 78 Ill.2d 106, 110.) To compare the conduct of the prosecutor in the case at bar with the prosecutor in Gold is ludicrous and requires no further consideration.
 3 Even assuming, however, that some of the prosecutor's comments could be deemed improper testimony, that testimony would not entitle defendant to a dismissal of the indictment. The grand jury is expected to indict an accused only if it decides that there is probable cause for believing that he has committed an offense. (People v. Rodgers (1982), 92 Ill.2d 283, 288.) Here, Detective Musial testified as to the intricate plan devised by the defendant to murder Stanley Fry and defendant's solicitation of Jeffrey Witzke to aid him in carrying out that plan. During his testimony, Musial told the jurors about his interviews with Fry and Witzke, Witzke's judicially authorized taped conversations with defendant, and the crime lab analysis of the cyanide-laced sandwich. Musial's sworn testimony alone was sufficient to indict defendant for solicitation to commit murder, attempted murder, and conspiracy and creates considerable doubt that the prosecutor's remarks, even if improper, resulted in substantial injustice to defendant.
We conclude that the comments cited by defendant neither separately nor cumulatively appear to have pressured or influenced the grand jury to return the indictment against defendant and that the prosecutor's remarks were made in the exercise of his function as advisor to the grand jury. Based on the transcript of the grand jury proceedings, no dismissal of the indictment is required.
Defendant next contends that the trial court erred in failing to suppress the "fruits" of the eavesdropping authorization. Defendant maintains that the petition to obtain the authorization was defective because it consisted of a summary of conversations between Witzke and defendant, which were recorded by Witzke, on his own and without authorization, on June 11, 1986. It is defendant's position that since the June 11 tapes, used to obtain the eavesdropping authorization, were tainted, the authorization itself was invalid, and all evidence *761 obtained as a result of the authorization should have been suppressed.
 4 The Illinois eavesdropping statute prohibits the use of an eavesdropping device to record all or part of any conversation unless all parties to the conversation consent or unless one party consents and prior judicial authorization is obtained in accordance with statutory directives. (Ill. Rev. Stat. 1985, ch. 38, par. 14-2.) Any evidence obtained in violation of the eavesdropping statute is inadmissible in any civil or criminal trial. (Ill. Rev. Stat. 1985, ch. 38, par. 14-5.) The Illinois Supreme Court has held that section 14-5 expressly adopts the "fruit of the poisonous tree doctrine" (Wong Sun v. United States (1963), 371 U.S. 471, 487-88, 9 L.Ed.2d 441, 455, 83 S.Ct. 407, 417), which requires the suppression of evidence obtained as the result of a violation of the eavesdropping statute. (People v. Maslowsky (1966), 34 Ill.2d 456, 464.) This exclusionary rule applies only to information derived from a process initiated by an unlawful act and does not extend to evidence obtained from an independent source. People v. Kezerian (1978), 63 Ill. App.3d 610, 620, rev'd on other grounds (1979), 77 Ill.2d 121.
In the instant case both Stanley Fry and Jeffrey Witzke consented to the recording of conversations between defendant and themselves on June 12, 1986. On that date, Detective Musial appeared before a trial judge and, based on his sworn petition and the consents of Fry and Witzke, obtained judicial authorization for the use of eavesdropping devices to record those conversations. Defendant maintains that Musial's petition was based strictly on recordings which Witzke made of conversations between defendant and Witzke on June 11, 1986, and which the trial court ruled were obtained illegally. However, our review of Musial's petition convinces us that the tapes did not comprise a primary basis for the petition and that when that portion of the petition which made reference to the June 11 tapes was "carved out" from the petition, as the trial judge suggested, a sufficient basis remained for the issuance of the eavesdropping order.
The petition set forth conversations Musial had with Fry and with Witzke, wherein the officer learned of the business transaction between Fry and the defendant. The petition stated that through these conversations the officer found out that Fry gave defendant "$27,000 [sic]" for a joint investment in certain securities, that Fry subsequently discovered the defendant had never opened a joint investment account but had lost the money on investments made in defendant's name only, that Witzke phoned Fry on June 11, 1986, impersonating Barry Haigh, a broker with the Chicago Mercantile Exchange, to tell Fry that his investments with defendant were worth $700,000, and *762 that later, in response to an earlier phone call Fry had placed to the real Barry Haigh, Fry learned that defendant had never made any investments with the broker. Additionally, the petition stated that, in discussions with Witzke, the officer learned of defendant's plan to murder Fry. Witzke explained how the murder was to be performed, what steps had been taken in preparation for the murder, and what amount defendant had agreed to pay Witzke for his help. The officer saw the receipt for the cyanide which Witzke had been instructed by defendant to purchase and observed the cyanide in Witzke's car trunk. Petitioner related that the Joliet State Crime Lab analyzed the cyanide and confirmed that it was, in fact, cyanide.
 5 During the first three pages of Musial's petition, the officer makes constant references to conversations he had with Fry and Witzke and to the information he gleaned from these conversations. At the very end of the third page of his petition, Musial states:
"Witzke also told me that he had secretly taped some of his conversations with Seehausen on June 11, 1986, which was done prior to his contact with the police or any law enforcement authority. Your affiant has listened to these tapes which confirmed the details related to me by Witzke."
This statement does not establish, as defendant claims, that Detective Musial was influenced by the June 11 tapes in preparing his petition. As related in his petition, Musial participated in conversations not only with Witzke but also with Fry before preparing the petition. Musial's knowledge of the murder attempt was derived from these conversations and was only later substantiated by the June 11 tapes. Consequently, we believe the petition establishes that the officer's knowledge of the murder attempt was independent of the eavesdropping by Witzke on June 11. The "fruit of the poisonous tree" doctrine (Wong Sun v. United States (1963), 371 U.S. 471, 487-88, 9 L.Ed.2d 441, 455, 83 S.Ct. 407, 417) cannot apply where, as here, the petitioner's knowledge was derived not from Witzke's recordings but from conversations Musial had with Fry and Witzke.
Based on the information given in Musial's petition and made under oath, it is evident that a sufficient basis existed for the eavesdropping authorization without the use of Witzke's illegally obtained June 11 tapes. Furthermore, the record indicates that both Fry and Musial appeared before the judge issuing the eavesdropping authorization, were placed under oath, and gave testimony. This fact, coupled with Musial's petition, leads to the presumption that the eavesdropping authorization proceedings and the conclusions reached therein were valid. People v. Moore (1980), 90 Ill. App.3d 760, 764.
*763  6 We conclude that the "totality of the circumstances," which is an appropriate analysis for determining "reasonable cause" on an application for use of an eavesdropping device (People v. Wrestler (1984), 121 Ill. App.3d 147, 155), was such that the issuing judge had a substantial basis for determining that reasonable cause existed for the issuance of an order authorizing use of eavesdropping devices. Therefore, the evidence obtained as a result of the eavesdropping authorization was not tainted.
Defendant, however, also argues that the tapes obtained as a result of the emergency eavesdropping authorization should be suppressed because the issuing judge failed immediately to review the tapes once they were returned to him as required by section 108A-7(b) of the Code of Criminal Procedure of 1963 (the Code) (Ill. Rev. Stat. 1985, ch. 38, par. 108A-7(b)). The tapes were obtained during the afternoon and evening hours of June 12, 1986. An order filed June 13, 1986, and signed by the issuing judge indicates that the tapes were returned to the court on that date by 10 a.m. and sealed by the clerk of the circuit court to be reopened for review by the court at a later date. An order dated June 19, 1986, indicates that the issuing judge had reviewed the tapes but does not establish the date on which he listened to them.
Section 108A-7(b) of the Code states in relevant part:
"Immediately after the expiration of the period of the order or extension or, where the recording was made in an emergency situation as defined in Section 108A-6, at the time of the request for approval subsequent to the emergency, all such recordings shall be made available to the judge issuing the order or hearing the application for approval of an emergency application.
The judge shall listen to the tapes, determine if the conversations thereon are within his order or were appropriately made in emergency situations, and make a record of such determination to be retained with the tapes." (Ill. Rev. Stat. 1985, ch. 38, par. 108A-7(b).)
Defendant interprets this statute to mean that upon return of the tapes to the issuing judge, the judge must immediately review the tapes. We, however, do not glean that interpretation from the statute. Rather, we are in agreement with the State, which argues that the concept of "immediacy" refers to the "immediate return" of the tapes to the court and not to the "immediate review" of those tapes.
 7 Section 108A-7(b) states in relevant part: "Immediately after expiration of * * * the order * * * all such recordings shall be made available to the judge issuing the order * * *." (Ill. Rev. Stat. 1985, ch. 38, *764 par. 108A-7(b).) In so stating, the statute requires the police immediately to return to the court any tapes obtained by means of the eavesdropping authorization order. This requirement of immediacy is designed to prevent any tampering with the recordings and to preserve the integrity of the tapes. (See People v. Nieves (1982), 92 Ill.2d 452, 454-63 (wherein the supreme court states that the statutory purpose of immediacy in section 108A-7(b) refers to the immediate return to the court of recordings made pursuant to an eavesdropping order and the sealing of those recordings to prevent tampering, alteration, or editing and to preserve the integrity of the recordings).) That purpose was accomplished in the instant case, as evidenced by the court's order showing that the tapes were delivered to the court by 10 a.m. on June 13, 1986, and sealed at that time.
 8 We conclude that the trial judge did not err in admitting the tapes attained as a result of the eavesdropping authorization because the authorization procedures, from the petition stage through the retention and review stages, were followed.
Defendant's final contention is that the trial court erred in failing to charge the jury with IPI Criminal 2d No. 3.17, dealing with accomplice testimony. IPI Criminal 2d No. 3.17 provides:
"When a witness says he was involved in the commission of a crime with the defendant, the testimony of that witness is subject to suspicion and should be considered by you with caution. It should be carefully examined in light of the other evidence in the case."
Defendant maintains that the trial court's failure to charge the jury with this instruction left the jury without legal direction as to the weight the testimony of Jeffrey Witzke, the State's key witness, was to be accorded and as to the jury's legal obligation to scrutinize Witzke's testimony.
 9 An accomplice is one who knowingly, voluntarily, and with common intent with the principal offender unites in the commission of a crime. (People v. Lashmett (1984), 126 Ill. App.3d 340, 346.) The test for determining whether one is an accomplice is whether he could have been indicted for the offense either as a principal or on an accountability theory. (People v. Travis (1981), 94 Ill. App.3d 983, 991.) To be accountable, a person must possess the mental state required for the offense, and before or during the offense aid in its commission. (Ill. Rev. Stat. 1985, ch. 38, par. 5-2(c); People v. Chaney (1987), 157 Ill. App.3d 552, 562.) However, a person is not so accountable if before the commission of the offense
"he terminates his effort to promote or facilitate such commission, *765 and does one of the following: wholly deprives his prior efforts of effectiveness in such commission, or gives timely warning to the proper law enforcement authorities, or otherwise makes proper effort to prevent the commission of the offense." (Ill. Rev. Stat. 1985, ch. 38, par. 5-2(c)(3).)
If a witness is not an accomplice under the accepted test, it is not error for the trial court to refuse to give a tendered instruction regarding the testimony of an accomplice. Travis, 94 Ill. App.3d at 991.
In the instant case, Witzke could not have been indicted for the offense of attempted murder as a principal or on an accountability theory. Witzke did not possess the necessary mental state as evidenced by his contacting Fry to tell him of defendant's murder plan and by his cooperating with the police to gather evidence against defendant. The first sentence of IPI Criminal 2d No. 3.17 states in pertinent part: "When a witness [has been] involved in the commission of a crime with the defendant * * *." (IPI Criminal 2d No. 3.17.) As the trial judge pointed out, this phrase does not apply to Witzke under the circumstances of this case, since by his timely warning Witzke terminated his involvement in defendant's scheme prior to its commission.
Nevertheless, the defendant argues that certain acts performed by Witzke facilitated defendant's offenses prior to Witzke's withdrawal from defendant's scheme and established the necessary common criminal intent between defendant and Witzke. Therefore, defendant asserts, IPI Criminal 2d No. 3.17 should have been given. We do not agree.
Giving the accomplice instruction depends upon the circumstances of each case. (See People v. Krush (1983), 120 Ill. App.3d 614, 618.) Unlike other cases where an individual knew of a defendant's intention to kill another but did nothing to prevent it, Witzke both abandoned the intention he had to help defendant kill Fry and took action to prevent that killing. In People v. Grabbe (1986), 148 Ill. App.3d 678, the testimony of Vicki McCallister established that she knew defendant, Fred Grabbe, intended to kill his wife but that she did nothing to prevent it. In fact, shortly before the date of the murder, defendant twice told McCallister that he intended to kill his wife. On the date of the murder, McCallister hid while defendant choked his wife to death and then helped defendant dispose of the body.
At trial the court first indicated that it would give the accomplice testimony instruction because McCallister had also been charged with murder. Later, however, when it was revealed that charges against McCallister were brought by information and that no probable cause hearing had ever been held, the court decided it would not give the *766 instruction. The appellate court determined that the lower court's refusal to give the instruction was error because McCallister knew prior to the murder that defendant intended to kill his wife and later aided him in disposing of her body. These facts established that there was probable cause to believe McCallister was guilty of murder by accountability and, therefore, was an accomplice to the offense.
In the instant case Witzke knew that defendant intended to kill Fry, but Witzke took steps to prevent Fry's murder by contacting Fry and by agreeing to act as an informant to gather evidence against defendant. Witzke's association with the police prevented the successful commission of the offense and relieved Witzke of accountability for the offense.
We note that the court did give IPI Criminal 2d No. 1.02, the standard credibility instruction, to the jury. As the State points out, that instruction has been found to be sufficient in instructing the jury to scrutinize a witness' testimony where a witness was granted immunity in return for his testimony (People v. Kraman (1981), 96 Ill. App.3d 390, 403), and, therefore, it would seem equally or even more satisfactory where, as here, the witness (Witzke) cooperated without receiving any promises of immunity.
 10 It is the jury's function to assess the credibility of the witnesses, to determine the weight to be credited to such evidence, and to evaluate the inferences to be drawn from it. (People v. Jarvis (1987), 158 Ill. App.3d 415, 425.) Here, the jury heard Witzke's testimony regarding his initial participation in defendant's plan and his subsequent withdrawal from that plan. The jury also heard the judicially authorized recordings of the conversations between Witzke and defendant on the date of the murder attempt. We believe that this jury, which had the opportunity to hear and observe Witzke over a period of four days, was in the best position to evaluate his credibility and to determine the weight to be given to his testimony. No further cautionary instruction was required. We conclude that, under the circumstances presented in the instant case, the trial court's refusal to give the accomplice instruction with respect to Witzke's testimony did not constitute reversible error.
Based on all of the reasons given above, the judgment of the circuit court of Du Page County is affirmed.
Affirmed.
DUNN and REINHARD, JJ., concur.
