Prosecutors withdrew all 17 charges against four police officers who were accused of planting heroin on a suspect's dashboard three years ago in a Toronto courtroom on Thursday.

The officers faced nine counts of obstructing justice and eight counts of perjury.

The Crown said there were "privilege issues at play" and as a result, couldn't provide defence lawyers with full disclosure of evidence.

"This was definitely a win," defence lawyer Peter Brauti told reporters. "The officers maintained their innocence right from the start."

While the details on why disclosure couldn't be given remain unclear, Brauti argued the outcome was inevitable.

"I don't think that this case could have gone ahead no matter what because it was more a matter of disclosure not being produced to the defence," he said.

"I don't think that disclosure was ever going to reach our hands and I don't think at the end of the day we would have had a trial in any event."

The charges arose from the arrest of Nguyen Son Tran on Jan. 15, 2014. The investigation was carried out by officers from Toronto Police Services Professional Standards.

The four officers who were charged are:

Const. Jeffrey Tout , 41, 17 years of service, assigned to 55 Division. It is alleged he provided false court testimony, and was charged with two counts of obstructing justice and two counts of perjury.

, 41, 17 years of service, assigned to 55 Division. It is alleged he provided false court testimony, and was charged with two counts of obstructing justice and two counts of perjury. Det. Const. Benjamin Elliott , 32, nine years of service, 55 Division. Charged with three counts of obstructing justice and three counts of perjury.

, 32, nine years of service, 55 Division. Charged with three counts of obstructing justice and three counts of perjury. Const. Michael Taylor , 34, 11 years of service, 51 Division. Charged with two counts of obstructing justice, one count of perjury.

, 34, 11 years of service, 51 Division. Charged with two counts of obstructing justice, one count of perjury. Det. Const. Fraser Douglas, 37, 14 years of service, 55 Division. Charged with two counts of obstructing justice, two counts of perjury.

They were all suspended with pay while the case went to court.

While Mike McCormack, president of Toronto Police Association, said they should be brought back to active duty soon, he explained the final decision to lift their suspensions is made by the Toronto Police Service.

"Our officers asserted the position that they were not guilty," said McCormack.

"Now it's time to get on with their lives and see what's next."