NAIROBI (Reuters) - A Kenyan court threw out charges on Wednesday against a junior minister and a legislator accused of inciting violence in comments they made after an ambush in which rustlers from their ethnic tribe are suspected of killing at least 32 police.

The ambush this month in a remote northern region was described as the worst single attack on police in Kenya's history.

Wildlife Assistant Minister Josephat Nanok and legislator David Ethuro, both members of the Turkana tribe, were charged on Monday with making comments that implied support for the attack.

The judge said he had quashed the case because the charge sheet did not indicate where the comments were made, and contained a verbatim quote which could not have been the exact words spoken by the two men.

"I find the charge to be defective and I reject it since the charge does not indicate where in the Kenyan capital Nairobi the words were uttered," Waweru Kiarie, Kenya's Chief Magistrate, said in his ruling.

In a partial quote from the charge sheet, the two politicians accused the police of bias towards rival Pokot and Samburu tribes.

"You don't want to disarm the Pokot, Samburu, it is only the Turkanas you want to disarm," the charge sheet quoted them as saying.

The men have not denied making the comments, but say they are protected from prosecution by the National Assembly Privileges and Immunities Act as their conversation took place within parliament.

Officers were hunting down Turkana cattle thieves who had stolen livestock from the Samburu tribe when they came under machinegun and rocket-propelled grenade fire, in an ambush police said was conducted with "military precision".

Media reports said up to 42 bodies had been recovered in the rugged Suguta valley where the attack occurred.

Five local leaders have also been charged in connection with the police killings.

(Reporting by Humphrey Malalo; Writing by James Macharia; Editing by Sophie Hares)