A Papua New Guinea court has ruled that a government decision to disband a national anti-corruption investigative agency cannot be overturned.
The government decided to disband the Task Force Sweep team in 2014, shortly after the agency pursued the arrest of prime minister over an alleged fraud case.
Mr O'Neill's government originally commissioned the investigative team in 2011 to probe corrution within government departments.
However its inquiries into alleged illegal state payments to a law firm led the team to seek an arrest warrant for Mr O'Neill himself.
He subsequently accused Taskforce Sweep of becoming politically compromised and in June 2014 moved to disband the team.
The former head of Taskforce Sweep Sam Koim filed an application to challenge the move in the national court.
However, Justice Colin Makail has dismissed the application, saying the court cannot review a policy decision by the government.
He ruled that the National Executive Committee had the authority to change its policy decisions at any time.
The court also said that Mr Koim lacked legal standing to commence the proceeding as chairman of the team because his contract of employment expired in June 2014.