FRESNO, Calif. AP – A man with a history of mental illness burst into a packed courtroom Monday wielding two carving knives and was shot to death as he threatened a judge he may have blamed for his misfortune, authorities said.

Robert Eaton, 40, had an extensive arrest record and last year, rammed his car into the Merced County courthouse out of anger that he was refused treatment by a mental health facility, Merced County Sheriff Mark Pazin said. Merced is about 50 miles northwest of Fresno.